/* URL IMPORTS */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

:root {
    --sage-green: #8BA888;
    --soft-blue: #A8C5DA;
    --warm-coral: #F4A89F;
    --attention-orange: #E49741;
    --warm-bg: #F8F6F3;
    --warm-card: #FFFFFF;
    --warm-border: #E8E4DF;
    --text-primary: #2D3E3F;
    --text-secondary: #5A6C6D;
    --aside-surface: #FBFCF9;
    --aside-header-surface: #FFFFFF;
    --aside-border: #E3E8DB;
    --aside-ink: #243D2E;
    --aside-muted: #5A6C6D;
    --aside-focus: #6B8B6E;
    --aside-shadow: rgba(31, 58, 42, 0.16);
    --action-primary: #4F6B53;
    --action-primary-hover: #3F5743;
    --page-header-title: var(--text-primary);
    --page-header-description: #354748;
    --page-header-icon: var(--action-primary);
    --page-header-icon-surface: #ECF1EC;
    --page-header-divider: #C7D0C4;
    --page-header-focus: var(--aside-focus);
    --page-header-font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --page-header-title-size: 1.875rem;
    --page-header-title-weight: 700;
    --page-header-title-leading: 1.2;
    --page-header-title-tracking: -0.025em;
    --page-header-description-size: 1rem;
    --page-header-description-leading: 1.5;
    --page-header-icon-gap: 1rem;
    --page-header-content-gap: 1.5rem;
    --page-header-padding-start: 0.25rem;
    --page-header-padding-end: 1.75rem;
    --page-shell-panel-inset: 2rem;
    --danger-surface: #FCE8E8;
    --danger-text: #7A252C;
    --success-surface: #EAF4EA;
    --success-text: #315B3A;
    --warning-surface: #FBF1D6;
    --warning-text: #66470C;
    --info-surface: #EAF2F7;
    --info-text: #315469;
    --neutral-surface: #EEF1F0;
    --neutral-text: #465554;
    --agenda-virtual-surface: #EAF1F5;
    --agenda-virtual-border: #BFD1DC;
    --agenda-virtual-ink: #294753;
    --agenda-virtual-muted: #4A6570;
    --agenda-virtual-icon-surface: #D5E5EC;
    --agenda-virtual-icon-ink: #365F73;
    --agenda-group-surface: #E9EEF5;
    --agenda-group-border: #ADBED0;
    --agenda-group-ink: #263F55;
    --agenda-group-muted: #496174;
    --agenda-group-icon-surface: #D3DEEA;
    --agenda-group-icon-ink: #3D5D77;
    --agenda-anonymous-surface: #F8EDF4;
    --agenda-anonymous-border: #E2BFD2;
    --agenda-anonymous-ink: #503448;
    --agenda-anonymous-muted: #6B5262;
    --agenda-anonymous-icon-surface: #EFD6E4;
    --agenda-anonymous-icon-ink: #765069;
    --agenda-direct-surface: #EAF3F0;
    --agenda-direct-border: #BAD2C9;
    --agenda-direct-ink: #27463D;
    --agenda-direct-muted: #4B655D;
    --agenda-direct-icon-surface: #D3E6DF;
    --agenda-direct-icon-ink: #356354;
    --focus-ring: var(--aside-focus);
    --z-dropdown: 1030;
    --z-sticky: 1040;
    --z-modal-backdrop: 1050;
    --z-modal: 1060;
    --z-modal-raised: 1090;
    --z-toast: 1100;
    --z-tooltip: 1110;
    --z-aside-panel: 1055;
    --z-aside-resizer: 1056;
    --z-aside-drag: 1058;
    --strength-empty: var(--text-secondary);
    --strength-weak: var(--warm-coral);
    --strength-medium: #D9A441;
    --strength-good: var(--soft-blue);
    --strength-strong: var(--sage-green);

    /* Spacing & Sizing Tokens */
    --spacing-header: clamp(2rem, 4vw + 1rem, 4rem);
    --btn-font-size: clamp(0.95rem, 0.5vw + 0.8rem, 1.125rem);
    --btn-padding-y: clamp(0.6rem, 0.5vw + 0.4rem, 1rem);
    --btn-padding-x: clamp(1.25rem, 1.5vw + 0.5rem, 2rem);

    /* Input Tokens */
    --input-font-size: clamp(0.9rem, 0.5vw + 0.75rem, 1rem);
    --input-padding-y: clamp(0.75rem, 0.5vw + 0.5rem, 1rem);
    --input-padding-x: clamp(1rem, 1vw + 0.5rem, 1.5rem);

    /* Typography Tokens */
    --h1-size: clamp(2rem, 5vw, 3.5rem);
    --h2-size: clamp(1.75rem, 4vw, 2.5rem);
    --h3-size: clamp(1.5rem, 3vw, 2rem);
    --h4-size: clamp(1.25rem, 2vw, 1.75rem);
    --h5-size: clamp(1.1rem, 1.5vw, 1.5rem);
    --h6-size: clamp(1rem, 1vw, 1.25rem);
}

/* CSP-safe utilities for documented component states. */
.text-sage {
    color: var(--action-primary);
}

.hero-content {
    position: relative;
    z-index: 1;
}

/* Page header */
.app-page-shell {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding-inline-start: env(safe-area-inset-left, 0px);
    padding-inline-end: env(safe-area-inset-right, 0px);
}

.app-page-shell > .landing-page-container {
    padding-top: var(--page-shell-panel-inset);
}

.app-page-header {
    display: flex;
    flex: 0 0 auto;
    align-items: flex-start;
    gap: var(--page-header-icon-gap);
    margin: 0 0 var(--page-header-content-gap);
    padding: var(--page-header-padding-start) 0 var(--page-header-padding-end);
    color: var(--page-header-title);
    border-bottom: 1px solid var(--page-header-divider);
    font-family: var(--page-header-font-family);
    font-kerning: normal;
    font-optical-sizing: auto;
}

.app-page-header__icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    color: var(--page-header-icon);
    background: var(--page-header-icon-surface);
    border-radius: 0.75rem;
    font-size: 1.25rem;
}

.app-page-header__copy {
    flex: 1 1 auto;
    min-width: 0;
    overflow-wrap: anywhere;
}

.app-page-header h1 {
    max-width: 42ch;
    margin: 0;
    color: var(--page-header-title);
    border: 0;
    font-size: var(--page-header-title-size) !important;
    font-weight: var(--page-header-title-weight);
    line-height: var(--page-header-title-leading);
    letter-spacing: var(--page-header-title-tracking);
    text-wrap: balance;
}

.app-page-header p {
    max-width: 65ch;
    margin: 0.5rem 0 0;
    color: var(--page-header-description);
    font-size: var(--page-header-description-size);
    line-height: var(--page-header-description-leading);
    text-wrap: pretty;
}

.app-page-header__actions {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-inline-start: auto;
}

.app-page-header__actions .btn,
.app-page-header__action {
    min-height: 44px;
}

.app-page-header__actions .btn {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

.app-page-header__actions :is(a, button):focus-visible {
    outline: 3px solid var(--page-header-focus);
    outline-offset: 3px;
    box-shadow: none;
}

.app-page-shell--workspace {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
}

@media (max-width: 767.98px) {
    .app-page-header {
        display: grid;
        grid-template-columns: 2.75em minmax(0, 1fr);
        column-gap: 0.75em;
        row-gap: 0.75em;
        margin: 0 0 1.25em;
        padding: 0.25em 0 1.25em;
        font-size: 1.333333rem;
    }

    .app-page-header__icon {
        grid-column: 1;
        grid-row: 1;
        width: 2.75em;
        height: 2.75em;
        border-radius: 0.75em;
        font-size: 1em;
    }

    .app-page-header__icon i {
        font-size: 1.125em;
    }

    .app-page-header__copy {
        grid-column: 2;
        grid-row: 1;
        font-size: 1em;
    }

    .app-page-header h1 {
        font-size: 1.5625em !important;
    }

    .app-page-header p {
        margin-top: 0.5em;
        font-size: 1em;
        line-height: 1.5;
    }

    .app-page-header__actions {
        grid-column: 2;
        grid-row: 2;
        min-width: 0;
        width: 100%;
        justify-content: flex-start;
        gap: 0.5em;
        margin-inline-start: 0;
        padding: 0;
        font-size: 1em;
    }

    .app-page-header__actions .btn {
        font-size: 0.875em;
    }

    .app-page-header__actions .btn i {
        font-size: 1em;
    }

    .app-page-header__actions .app-page-header__action:not(.btn) {
        font-size: 1.125em;
    }
}

.progress-line--half {
    width: 50%;
}

/* Form Controls */
.form-control-custom {
    display: block;
    width: 100%;
    font-family: 'DM Sans', sans-serif;
    font-size: var(--input-font-size);
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: white;
    background-clip: padding-box;
    border: 2px solid var(--warm-border);
    border-radius: 0.75rem;
    padding: var(--input-padding-y) var(--input-padding-x);
    transition: border-color 0.2s ease-out, box-shadow 0.2s ease-out;
    height: auto;
}

select.form-control-custom {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%235A6C6D' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 16px 12px;
    padding-right: 2.5rem;
}

.form-control-custom:focus {
    border-color: var(--action-primary);
    box-shadow: 0 0 0 3px rgba(79, 107, 83, 0.16);
    outline: none;
    color: var(--text-primary);
    background-color: white;
}

.form-control-custom[aria-invalid="true"] {
    border-color: var(--danger-text);
}

.form-control-custom::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

/* Landing Page Styles */
.landing-page-container {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    /*background-color: var(--warm-bg);*/
    background-color: #f8f6f3a1;
    color: var(--text-primary);
    border-radius: 15px;
    backdrop-filter: blur(4px);
    outline: 1px solid #ffffff61;
}

.hero-section {
    /*background-color: var(--warm-bg);*/
    padding-top: var(--spacing-header) !important;
    padding-bottom: var(--spacing-header) !important;
    position: relative;
    overflow: hidden;
}

/* Blob Background Effect */
.hero-blob-1 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 20%, rgba(139, 168, 136, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(168, 197, 218, 0.2) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.badge-pill-custom {
    background-color: rgba(139, 168, 136, 0.1);
    color: var(--action-primary);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    display: inline-block;
}

.badge-notification {
    background-color: var(--warm-coral);
    color: white;
    font-weight: 700;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    margin-left: 0.5rem;
    vertical-align: middle;
    line-height: 1;
}

.display-4 {
    /* font-size: var(--h1-size);
     */
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

h1 {
    font-size: var(--h1-size) !important;
}

h2 {
    font-size: var(--h2-size) !important;
}

.factura-csp-dialog__title {
    font-size: 1.375rem !important;
}

.csp-dialog__title {
    font-size: 1.5rem !important;
}

h3 {
    font-size: var(--h3-size) !important;
}

h4 {
    font-size: var(--h4-size) !important;
}

h5 {
    font-size: var(--h5-size) !important;
}

h6 {
    font-size: var(--h6-size) !important;
}

.lead {
    color: var(--text-secondary);
    font-size: 1.25rem;
    line-height: 1.6;
}

.btn-gradient-primary {
    background: var(--action-primary);
    color: white;
    border: none;
    border-radius: 1rem;
    /* rounded-2xl */
    padding: var(--btn-padding-y) var(--btn-padding-x);
    font-weight: 600;
    font-size: var(--btn-font-size);
    transition: background-color 0.2s ease-out, box-shadow 0.2s ease-out, transform 0.2s ease-out;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.btn-gradient-primary:hover {
    background: var(--action-primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.14);
    color: white;
}

.btn-gradient-primary:focus-visible,
.btn-outline-custom:focus-visible,
.btn-outline-custom-sm:focus-visible,
.btn-action:focus-visible {
    outline: 3px solid var(--aside-focus);
    outline-offset: 2px;
}

.btn-gradient-primary:active {
    transform: translateY(0);
}

.btn-gradient-primary:disabled,
.btn-gradient-primary[aria-disabled="true"] {
    opacity: 0.58;
    cursor: not-allowed;
    transform: none;
}

.btn-outline-custom {
    background-color: white;
    color: var(--text-primary);
    border: 2px solid var(--warm-border);
    border-radius: 1rem;
    /* rounded-2xl */
    padding: var(--btn-padding-y) var(--btn-padding-x);
    font-weight: 600;
    font-size: var(--btn-font-size);
    transition: color 0.2s ease-out, border-color 0.2s ease-out, background-color 0.2s ease-out;
}

.btn-outline-custom:hover {
    border-color: var(--action-primary);
    color: var(--text-primary);
}

.btn-outline-custom-sm {
    background-color: white;
    color: var(--text-primary);
    border: 2px solid var(--warm-border);
    border-radius: 0.5rem;
    padding: 0.5rem 1rem;
    font-weight: 600;
    font-size: 0.85rem;
    transition: color 0.2s ease-out, border-color 0.2s ease-out, background-color 0.2s ease-out, transform 0.2s ease-out;
}

.btn-outline-custom-sm:hover {
    border-color: var(--action-primary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.btn-outline-custom.active {
    background: var(--action-primary);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
}

.card-custom {
    background-color: white;
    border-radius: 1.5rem;
    /* rounded-3xl */
    border: none;
    padding: 2rem;
    box-shadow: 0 10px 15px -3px rgba(139, 168, 136, 0.05);
    transition: all 0.3s ease;
}

.card-custom:hover {
    box-shadow: 0 20px 25px -5px rgba(139, 168, 136, 0.1);
    transform: translateY(-2px);
}

.icon-box-custom {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    /* rounded-2xl */
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease;
}

.card-custom:hover .icon-box-custom {
    transform: scale(1.1);
}

/* Gradients for Icons */
.bg-gradient-1 {
    background: linear-gradient(135deg, var(--sage-green), var(--soft-blue));
}

.bg-gradient-2 {
    background: linear-gradient(135deg, var(--soft-blue), var(--warm-coral));
}

.bg-gradient-3 {
    background: linear-gradient(135deg, var(--warm-coral), var(--sage-green));
}

.bg-gradient-4 {
    background: linear-gradient(135deg, var(--sage-green), var(--warm-coral));
}

.bg-gradient-5 {
    background: linear-gradient(135deg, var(--soft-blue), var(--sage-green));
}

.bg-gradient-6 {
    background: linear-gradient(135deg, var(--warm-coral), var(--soft-blue));
}

.text-white-icon {
    color: white;
}

/* Existing modal/alert close override */
button.psy-alert-close,
button.psy-modal-close {
    top: 7px;
}

.enlaces-pago-container {
    text-align: left;
    max-width: 400px;
    margin: 0 auto;
}

.enlace-pago-item {
    border: 1px solid var(--warm-border);
    border-radius: 0.375rem;
    padding: 0.75rem;
    transition: all 0.2s;
    cursor: pointer;
}

.enlace-pago-item:hover {
    border-color: var(--sage-green);
    background-color: #f8f9fa;
}

.enlace-pago-item:has(.custom-control-input:checked) {
    border-color: var(--sage-green);
    box-shadow: 0 2px 4px rgba(139, 168, 136, 0.3);
    background-color: rgba(139, 168, 136, 0.1);
}

.enlace-pago-item .custom-control-input:checked~.custom-control-label::before {
    border-color: var(--sage-green);
    background-color: var(--sage-green);
}

/* Social Proof Stars */
.star-icon {
    color: var(--warm-coral);
    fill: var(--warm-coral);
}

/* Feature List Items */
.feature-list-item {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    border-radius: 1rem;
    margin-bottom: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-list-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.bg-soft-green {
    background: linear-gradient(135deg, rgba(139, 168, 136, 0.2), rgba(139, 168, 136, 0.05));
}

.bg-soft-blue {
    background: linear-gradient(135deg, rgba(168, 197, 218, 0.2), rgba(168, 197, 218, 0.05));
}

.bg-soft-coral {
    background: linear-gradient(135deg, rgba(244, 168, 159, 0.2), rgba(244, 168, 159, 0.05));
}

.icon-box-small {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}

/* Authentication and 2FA */
.auth-page {
    display: flex;
    justify-content: center;
    padding: clamp(2rem, 6vw, 4.5rem) 1rem;
}

.auth-card {
    background-color: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: 1.5rem;
    box-shadow: 0 20px 35px -20px rgba(45, 62, 63, 0.35);
    max-width: 34rem;
    padding: clamp(1.5rem, 4vw, 2.5rem);
    width: 100%;
}

.auth-card-wide {
    max-width: 64rem;
}

.auth-header {
    margin-bottom: 1.5rem;
    text-align: center;
}

.auth-kicker {
    color: var(--sage-green);
    display: block;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.auth-title {
    color: var(--text-primary);
    font-size: clamp(1.7rem, 4vw, 2.35rem) !important;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 0.75rem;
}

.auth-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.55;
    margin: 0 auto;
    max-width: 30rem;
}

.auth-actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.auth-link-button {
    background: transparent;
    border: 0;
    color: var(--sage-green);
    display: inline-block;
    font-weight: 700;
    padding: 0;
    text-decoration: none;
}

.auth-link-button:hover {
    color: var(--text-primary);
    text-decoration: none;
}

.auth-link-button:disabled {
    color: var(--text-secondary);
    cursor: not-allowed;
    opacity: 0.75;
}

.auth-code-entry {
    margin: 1.5rem auto 0;
    max-width: 25rem;
    position: relative;
}

.auth-code-cells {
    display: grid;
    gap: 0.5rem;
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.auth-code-cell {
    align-items: center;
    aspect-ratio: 1;
    background: var(--warm-card);
    border: 2px solid var(--warm-border);
    border-radius: 0.75rem;
    color: var(--text-primary);
    display: flex;
    font-size: clamp(1.35rem, 4vw, 2rem);
    font-weight: 800;
    justify-content: center;
    line-height: 1;
    transition: all 0.2s ease;
}

.auth-code-entry:focus-within .auth-code-cell-active,
.auth-code-cell-filled {
    border-color: var(--sage-green);
    box-shadow: 0 0 0 0.2rem rgba(139, 168, 136, 0.22);
}

.auth-code-native {
    border: 0;
    height: 1px;
    left: 50%;
    opacity: 0;
    outline: 0;
    position: absolute;
    top: 50%;
    width: 1px;
}

.auth-method-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
}

.auth-method-card {
    align-items: flex-start;
    background-color: var(--warm-card);
    border: 2px solid var(--warm-border);
    border-radius: 1rem;
    cursor: pointer;
    display: flex;
    gap: 1rem;
    padding: 1.25rem;
    transition: all 0.2s ease;
}

.auth-method-card:hover,
.auth-method-card:has(input:checked) {
    border-color: var(--sage-green);
    box-shadow: 0 10px 20px -14px rgba(45, 62, 63, 0.35);
    transform: translateY(-1px);
}

.auth-method-card input {
    margin-top: 0.45rem;
}

.auth-method-body {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.auth-method-title {
    align-items: center;
    color: var(--text-primary);
    display: flex;
    flex-wrap: wrap;
    font-weight: 800;
    gap: 0.5rem;
}

.auth-method-description {
    color: var(--text-secondary);
    line-height: 1.45;
}

.auth-method-icon {
    color: var(--sage-green);
}

.auth-provider-card {
    background-color: var(--warm-card);
    border: 2px solid var(--warm-border);
    border-radius: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    transition: all 0.2s ease;
}

.auth-provider-card-active {
    border-color: var(--sage-green);
    box-shadow: 0 12px 24px -18px rgba(45, 62, 63, 0.35);
}

.auth-provider-card-header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.auth-provider-title {
    color: var(--text-primary);
    font-size: 1.15rem !important;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.auth-provider-state {
    background: rgba(139, 168, 136, 0.15);
    border-radius: 999px;
    color: var(--text-primary);
    font-size: 0.82rem;
    font-weight: 800;
    padding: 0.35rem 0.75rem;
    white-space: nowrap;
}

.auth-provider-state-muted {
    background: rgba(90, 108, 109, 0.12);
    color: var(--text-secondary);
}

.auth-provider-actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.auth-qr-panel {
    align-items: center;
    background: linear-gradient(135deg, rgba(139, 168, 136, 0.13), rgba(168, 197, 218, 0.18));
    border: 1px solid var(--warm-border);
    border-radius: 1rem;
    display: grid;
    gap: 1.5rem;
    grid-template-columns: auto minmax(0, 1fr);
    padding: 1.25rem;
}

.auth-qr-box {
    align-items: center;
    background: white;
    border: 1px solid var(--warm-border);
    border-radius: 1rem;
    display: flex;
    height: 12rem;
    justify-content: center;
    padding: 0.85rem;
    width: 12rem;
}

.auth-qr-box img,
.auth-qr-box canvas,
.auth-qr-box svg {
    height: 100% !important;
    width: 100% !important;
}

.auth-manual-key {
    background: white;
    border: 1px solid var(--warm-border);
    border-radius: 0.75rem;
    color: var(--text-primary);
    display: block;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.85rem 1rem;
    text-align: center;
    word-break: break-word;
}

/* 2FA management hub */
.df-page,
.df-surface {
    --df-sage-50: #f4f8f1;
    --df-sage-100: #e7efe1;
    --df-sage-200: #cfddc7;
    --df-sage-300: #a9c1a4;
    --df-sage-500: #6b8b6e;
    --df-sage-700: #3f5942;
    --df-sage-900: #1f3a2a;
    --df-ink: #243d2e;
    --df-ink-2: #3a5142;
    --df-ink-muted: #6f7d72;
    --df-ink-faint: #95a299;
    --df-bg-soft: #fbfcf9;
    --df-border: #e3e8db;
    --df-border-2: #d4dccb;
    --df-danger: #b1463a;
    --df-danger-bg: #fbeae6;
    --df-danger-border: #efc8bf;
    --df-warn-bg: #fdf3d2;
    --df-warn-border: #ecd589;
    --df-warn-text: #7e6212;
    --df-info-bg: #eaf1f6;
    --df-info-text: #2d5b78;
    --df-radius-md: 0.625rem;
    --df-radius-lg: 0.875rem;
    --df-shadow-1: 0 1px 2px rgba(31, 58, 42, 0.06), 0 1px 1px rgba(31, 58, 42, 0.04);
    color: var(--df-ink);
}

.df-surface {
    align-items: flex-start;
    background:
        radial-gradient(circle at top left, rgba(136, 165, 133, 0.16), transparent 34rem),
        linear-gradient(135deg, #f8f6f3 0%, #eef4eb 100%);
    display: flex;
    justify-content: center;
    min-height: auto;
    padding: clamp(1.75rem, 5vw, 3.5rem) 1rem;
}

.df-surface--login {
    text-align: center;
}

.df-auth-card {
    background: #fff;
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-lg);
    box-shadow: 0 18px 45px rgba(31, 58, 42, 0.14);
    max-width: 100%;
    padding: clamp(1.25rem, 3vw, 2rem);
    width: 30rem;
}

.df-auth-card--left {
    text-align: left;
}

.df-auth-card__head {
    margin-bottom: 1.25rem;
    text-align: center;
}

.df-auth-card__foot {
    margin-top: 1.25rem;
    text-align: center;
}

.df-auth-card__head .df-lede strong {
    color: var(--df-ink-2);
}

.df-auth-card .validation-summary-valid {
    display: none;
}

.df-auth-icon {
    margin: 0 auto 0.75rem;
}

.df-page .box-body {
    padding: clamp(1.25rem, 3vw, 2rem);
}

.df-page-head {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1.375rem;
}

.df-eyebrow {
    color: var(--df-sage-500);
    display: block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
}

.df-title {
    color: var(--df-ink);
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 500;
    letter-spacing: 0;
    margin: 0.25rem 0 0.375rem;
}

.df-title--xl {
    font-size: clamp(1.8rem, 3vw, 2rem) !important;
    line-height: 1.15;
}

.df-title--md {
    font-size: 1.1875rem !important;
    line-height: 1.3;
}

.df-title--lg {
    font-size: clamp(1.55rem, 3vw, 1.75rem) !important;
    line-height: 1.2;
}

.df-lede {
    color: var(--df-ink-muted);
    font-size: 0.875rem;
    line-height: 1.5;
}

.df-pill {
    align-items: center;
    background: var(--df-sage-50);
    border: 1px solid var(--df-sage-200);
    border-radius: 999px;
    color: var(--df-sage-700);
    display: inline-flex;
    flex: 0 0 auto;
    font-size: 0.72rem;
    font-weight: 700;
    gap: 0.375rem;
    letter-spacing: 0.02em;
    padding: 0.1875rem 0.625rem;
    white-space: nowrap;
}

.df-pill .dot {
    background: var(--df-sage-500);
    border-radius: 50%;
    height: 0.375rem;
    width: 0.375rem;
}

.df-pill--muted {
    background: #f1f3ee;
    border-color: var(--df-border);
    color: var(--df-ink-muted);
}

.df-pill--muted .dot {
    background: var(--df-ink-faint);
}

.df-pill--warn {
    background: var(--df-warn-bg);
    border-color: var(--df-warn-border);
    color: var(--df-warn-text);
}

.df-pill--warn .dot {
    background: #c89316;
}

.df-pill--rec {
    background: #eaf2e3;
    border-color: var(--df-sage-200);
    color: var(--df-sage-700);
}

.df-alert {
    align-items: flex-start;
    border-radius: var(--df-radius-md);
    display: flex;
    font-size: 0.8125rem;
    gap: 0.625rem;
    line-height: 1.45;
    margin-bottom: 1rem;
    padding: 0.625rem 0.875rem;
}

.df-alert--warn {
    background: var(--df-warn-bg);
    border: 1px solid var(--df-warn-border);
    color: var(--df-warn-text);
}

.df-alert--info {
    background: var(--df-info-bg);
    border: 1px solid #cfdce4;
    color: var(--df-info-text);
}

.df-alert--danger {
    background: var(--df-danger-bg);
    border: 1px solid var(--df-danger-border);
    color: var(--df-danger);
}

.df-alert ul {
    margin: 0;
    padding-left: 1rem;
}

.df-card {
    background: #fff;
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-lg);
    box-shadow: var(--df-shadow-1);
}

.df-grid-2 {
    align-items: start;
    display: grid;
    gap: 1.375rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.df-grid-2--recovery {
    grid-template-columns: minmax(0, 1.35fr) minmax(16rem, 0.65fr);
}

.df-codes-card {
    padding: 1rem;
}

.df-codes {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.df-codes__item {
    align-items: center;
    background: var(--df-bg-soft);
    border: 1.5px solid var(--df-border-2);
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    display: flex;
    gap: 0.625rem;
    min-height: 3.75rem;
    padding: 0.75rem 0.875rem;
}

.df-codes__item code {
    background: transparent;
    color: inherit;
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    overflow-wrap: anywhere;
    padding: 0;
}

.df-codes__num {
    align-items: center;
    background: #fff;
    border: 1px solid var(--df-border);
    border-radius: 999px;
    color: var(--df-sage-700);
    display: inline-flex;
    flex: 0 0 auto;
    font-size: 0.6875rem;
    font-weight: 800;
    height: 1.5rem;
    justify-content: center;
    width: 1.5rem;
}

.df-action-row {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
}

.df-save-card {
    background: var(--df-bg-soft);
    border-style: dashed;
    box-shadow: none;
    padding: 1rem;
}

.df-save-card__title {
    align-items: center;
    color: var(--df-ink);
    display: flex;
    font-size: 0.875rem;
    font-weight: 700;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.df-save-card__title i {
    color: var(--df-sage-700);
}

.df-save-card ul {
    color: var(--df-ink-muted);
    font-size: 0.8125rem;
    line-height: 1.6;
    margin: 0;
    padding-left: 1.125rem;
}

.df-copy-source {
    height: 1px;
    left: -9999px;
    opacity: 0;
    position: absolute;
    top: auto;
    width: 1px;
}

.df-qr-card {
    align-items: center;
    background: linear-gradient(135deg, rgba(136, 165, 133, 0.11), rgba(168, 197, 218, 0.16));
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-lg);
    display: grid;
    gap: 1.375rem;
    grid-template-columns: auto minmax(0, 1fr);
    padding: 1.25rem;
}

.df-qr-card__main {
    min-width: 0;
}

.df-qr {
    align-items: center;
    background: #fff;
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-lg);
    display: flex;
    height: 12rem;
    justify-content: center;
    padding: 0.875rem;
    width: 12rem;
}

.df-qr img,
.df-qr canvas,
.df-qr svg {
    height: 100% !important;
    width: 100% !important;
}

.df-copy-row {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.df-disclosure {
    margin-top: 0.5rem;
}

.df-disclosure summary {
    align-items: center;
    color: var(--df-sage-700);
    cursor: pointer;
    display: inline-flex;
    font-size: 0.78125rem;
    font-weight: 700;
    gap: 0.375rem;
}

.df-disclosure[open] summary i {
    transform: rotate(90deg);
}

.df-settings-list {
    overflow: hidden;
    padding: 0.375rem 0;
}

.df-row {
    align-items: center;
    border-bottom: 1px solid var(--df-border);
    display: flex;
    gap: 1.125rem;
    padding: 1.125rem 1.25rem;
}

.df-row:last-child {
    border-bottom: 0;
}

.df-row.is-active {
    background: linear-gradient(90deg, rgba(136, 165, 133, 0.07), transparent 80%);
}

.df-row.is-inactive,
.df-row.is-disabled {
    background: var(--df-bg-soft);
}

.df-row.is-disabled .df-row__title,
.df-row.is-disabled .df-row__desc {
    opacity: 0.85;
}

.df-row__icon {
    flex: 0 0 auto;
}

.df-icon-tile {
    align-items: center;
    background: var(--df-sage-50);
    border: 1px solid var(--df-sage-200);
    border-radius: var(--df-radius-md);
    color: var(--df-sage-700);
    display: inline-flex;
    height: 2.5rem;
    justify-content: center;
    width: 2.5rem;
}

.df-icon-tile--lg {
    border-radius: 0.75rem;
    height: 3rem;
    width: 3rem;
}

.df-icon-tile--neutral {
    background: #f1f3ee;
    border-color: var(--df-border);
    color: var(--df-ink-muted);
}

.df-icon-tile--danger {
    background: var(--df-danger-bg);
    border-color: var(--df-danger-border);
    color: var(--df-danger);
}

.df-row__main {
    flex: 1 1 auto;
    min-width: 0;
}

.df-row__title {
    align-items: center;
    color: var(--df-ink);
    display: flex;
    flex-wrap: wrap;
    font-size: 0.9375rem;
    font-weight: 700;
    gap: 0.625rem;
    margin-bottom: 0.125rem;
}

.df-row__desc {
    color: var(--df-ink-muted);
    font-size: 0.8125rem;
    line-height: 1.45;
}

.df-row__desc strong {
    color: var(--df-ink-2);
    font-weight: 700;
    overflow-wrap: anywhere;
}

.df-row__actions {
    align-items: center;
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

.df-sensitive-form {
    align-items: center;
    display: flex;
    gap: 0.5rem;
    margin: 0;
}

.df-sensitive-form--right {
    justify-content: flex-end;
}

.df-compact-input {
    border: 1px solid var(--df-border-2);
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    font-size: 0.8125rem;
    height: auto;
    max-width: 11rem;
    min-height: 2rem;
    padding: 0.375rem 0.625rem;
}

.df-compact-input:focus {
    border-color: var(--df-sage-500);
    box-shadow: 0 0 0 0.2rem rgba(136, 165, 133, 0.18);
}

.df-btn {
    align-items: center;
    appearance: none;
    background: transparent;
    border: 1px solid transparent;
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    cursor: pointer;
    display: inline-flex;
    font-size: 0.84375rem;
    font-weight: 700;
    gap: 0.5rem;
    justify-content: center;
    line-height: 1.2;
    padding: 0.5625rem 1rem;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    white-space: nowrap;
}

.df-btn:focus {
    outline: 2px solid var(--df-sage-300);
    outline-offset: 2px;
}

.df-btn:disabled {
    cursor: not-allowed;
    opacity: 0.62;
}

.df-btn--primary {
    background: var(--df-sage-700);
    border-color: var(--df-sage-700);
    color: #fff;
}

.df-btn--primary:hover {
    background: var(--df-sage-900);
    border-color: var(--df-sage-900);
    color: #fff;
}

.df-btn--ghost {
    background: #fff;
    border-color: var(--df-border-2);
    color: var(--df-ink);
}

.df-btn--ghost:hover {
    background: var(--df-sage-50);
    border-color: var(--df-sage-300);
    color: var(--df-ink);
}

.df-btn--danger {
    background: #fff;
    border-color: var(--df-danger-border);
    color: var(--df-danger);
}

.df-btn--danger:hover {
    background: var(--df-danger-bg);
    color: var(--df-danger);
}

.df-btn--danger-solid {
    background: var(--df-danger);
    border-color: var(--df-danger);
    color: #fff;
}

.df-btn--danger-solid:hover {
    background: #8e3024;
    border-color: #8e3024;
    color: #fff;
}

.df-btn--link {
    background: transparent;
    border: 0;
    color: var(--df-sage-700);
    padding-left: 0;
    padding-right: 0;
}

.df-btn--link:hover {
    color: var(--df-sage-900);
    text-decoration: underline;
}

.df-btn--danger-link {
    color: var(--df-danger);
}

.df-btn--lg {
    font-size: 0.90625rem;
    padding: 0.6875rem 1.25rem;
}

.df-btn--sm {
    font-size: 0.78125rem;
    min-height: 2rem;
    padding: 0.375rem 0.75rem;
}

.df-btn--block {
    width: 100%;
}

.df-method-divider {
    align-items: center;
    color: var(--df-ink-faint);
    display: flex;
    gap: 0.875rem;
    margin: 1rem 0;
}

.df-method-divider span {
    background: var(--df-border);
    flex: 1 1 auto;
    height: 1px;
}

.df-method-divider strong {
    flex: 0 0 auto;
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.df-method-list {
    display: grid;
    gap: 0.5rem;
}

.df-method {
    align-items: center;
    appearance: none;
    background: #fff;
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    cursor: pointer;
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    text-align: left;
    transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
    width: 100%;
}

.df-method:hover,
.df-method:focus {
    background: var(--df-sage-50);
    border-color: var(--df-sage-300);
    box-shadow: var(--df-shadow-1);
    outline: 0;
}

.df-method__icon {
    flex: 0 0 auto;
}

.df-method__main {
    display: grid;
    flex: 1 1 auto;
    gap: 0.125rem;
    min-width: 0;
}

.df-method__title {
    color: var(--df-ink);
    font-size: 0.875rem;
    font-weight: 800;
}

.df-method__desc {
    color: var(--df-ink-muted);
    font-size: 0.78125rem;
    line-height: 1.35;
}

.df-method__chevron {
    color: var(--df-ink-faint);
    flex: 0 0 auto;
    font-size: 0.75rem;
}

.df-danger-zone {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 1rem 0.25rem 0;
}

.df-danger-zone__text {
    align-items: center;
    color: var(--df-ink-muted);
    display: flex;
    font-size: 0.8125rem;
    gap: 0.5rem;
}

.df-page-foot {
    display: flex;
    gap: 0.625rem;
    justify-content: flex-end;
    margin-top: 1.375rem;
}

.df-verify-form {
    margin-top: 1.5rem;
}

.df-auth-code {
    margin-top: 1.25rem;
    position: relative;
}

.df-verify-block {
    position: relative;
}

.df-verify-block__entry {
    align-items: center;
    display: flex;
    gap: 0.875rem;
}

.df-otp {
    display: flex;
    gap: 0.625rem;
}

.df-otp--center {
    justify-content: center;
}

.df-otp__cell {
    align-items: center;
    background: var(--df-bg-soft);
    border: 1.5px solid var(--df-border-2);
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    display: flex;
    flex: 0 0 3.25rem;
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 1.5rem;
    font-weight: 600;
    height: 3.75rem;
    justify-content: center;
    line-height: 1;
    transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
    width: 3.25rem;
}

.df-verify-block:focus-within .df-otp__cell.is-active,
.df-otp__cell.is-filled {
    background: #fff;
    border-color: var(--df-sage-500);
    box-shadow: 0 0 0 0.2rem rgba(136, 165, 133, 0.18);
}

.df-auth-code.is-error .df-otp__cell.is-filled {
    border-color: var(--df-danger);
    color: var(--df-danger);
}

.df-help {
    color: var(--df-ink-muted);
    font-size: 0.78125rem;
    line-height: 1.45;
}

.df-help i {
    margin-right: 0.35rem;
}

.df-code-timer {
    margin: 1rem auto 0;
    max-width: 17.5rem;
}

.df-code-timer__track {
    background: var(--df-border);
    border-radius: 999px;
    height: 0.25rem;
    overflow: hidden;
}

.df-code-timer__track span {
    background: var(--df-sage-500);
    border-radius: inherit;
    display: block;
    height: 100%;
    transform-origin: left center;
}

.df-auth-links {
    align-items: center;
    display: flex;
    font-size: 0.8125rem;
    gap: 0.875rem;
    justify-content: center;
    margin-top: 0.75rem;
}

.df-auth-links span {
    color: var(--df-ink-faint);
}

.df-field {
    text-align: left;
}

.df-recovery-input {
    border-width: 1.5px;
    display: block;
    font-size: 1.25rem;
    font-weight: 600;
    height: 3.75rem;
    line-height: 1;
    margin: 0 auto;
    padding: 0 0.875rem;
    text-align: center;
    text-transform: uppercase;
}

.df-mt-3 {
    margin-top: 0.75rem;
}

.df-mt-2 {
    margin-top: 0.5rem;
}

.df-mt-4 {
    margin-top: 1rem;
}

.df-label {
    color: var(--df-ink-2);
    display: block;
    font-size: 0.8125rem;
    font-weight: 700;
    margin-bottom: 0.375rem;
    text-align: left;
}

.df-input {
    background: #fff;
    border: 1px solid var(--df-border-2);
    border-radius: var(--df-radius-md);
    color: var(--df-ink);
    font-size: 0.875rem;
    padding: 0.625rem 0.75rem;
    width: 100%;
}

.df-input:focus {
    border-color: var(--df-sage-500);
    box-shadow: 0 0 0 0.2rem rgba(136, 165, 133, 0.18);
    outline: 0;
}

.df-input--mono {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 0.8125rem;
    letter-spacing: 0.04em;
}

.df-dialog-popup {
    border: 1px solid var(--df-border);
    border-radius: var(--df-radius-lg);
    box-sizing: border-box;
    box-shadow: 0 20px 60px rgba(31, 58, 42, 0.25);
    color: var(--df-ink-2);
    overflow: hidden;
    padding: 0;
    width: min(30rem, calc(100vw - 2rem));
}

.df-dialog-html {
    margin: 0;
    padding: 0;
}

.df-dialog-confirm {
    text-align: left;
}

.df-dialog-confirm__head {
    align-items: flex-start;
    display: flex;
    gap: 0.875rem;
    padding: 1.25rem 1.375rem 0.25rem;
}

.df-dialog-confirm__eyebrow {
    color: var(--df-danger);
}

.df-dialog-confirm__title {
    margin-top: 0.125rem;
}

.df-dialog-confirm__body {
    color: var(--df-ink-2);
    font-size: 0.875rem;
    line-height: 1.55;
    padding: 0.25rem 1.375rem 1.125rem;
}

.df-dialog-confirm__field {
    margin-top: 0.75rem;
}

.df-dialog-popup .factura-csp-dialog__actions {
    background: var(--df-bg-soft);
    border-top: 1px solid var(--df-border);
    box-sizing: border-box;
    gap: 0.625rem;
    justify-content: space-between;
    margin: 0 !important;
    padding: 0.875rem 1.375rem;
    width: 100%;
}

.df-dialog-popup .factura-csp-dialog__actions .df-btn {
    margin: 0;
    min-width: 7.5rem;
}

.df-dialog-popup .factura-csp-dialog__confirm.df-btn--danger-solid {
    background: var(--df-danger) !important;
    border-color: var(--df-danger) !important;
    box-shadow: 0 1px 2px rgba(90, 38, 31, 0.16);
    color: #fff !important;
}

.df-dialog-popup .factura-csp-dialog__confirm.df-btn--danger-solid:hover {
    background: #8e3024 !important;
    border-color: #8e3024 !important;
    color: #fff !important;
}

.df-dialog-popup .factura-csp-dialog__cancel.df-btn--ghost {
    background: #fff !important;
    border-color: var(--df-border-2) !important;
    color: var(--df-ink) !important;
}

.df-dialog-popup .factura-csp-dialog__validation {
    background: var(--df-danger-bg);
    color: var(--df-danger);
    font-size: 0.8125rem;
    margin: 0.75rem 1.375rem 0;
}

@media (max-width: 767px) {
    .auth-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .auth-actions .btn,
    .auth-actions button,
    .auth-provider-actions,
    .auth-provider-actions form,
    .auth-provider-actions .btn {
        width: 100%;
    }

    .auth-qr-panel {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .auth-qr-box {
        height: min(72vw, 12rem);
        width: min(72vw, 12rem);
    }

    .df-page-head,
    .df-grid-2,
    .df-row,
    .df-danger-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .df-grid-2,
    .df-grid-2--recovery,
    .df-codes {
        grid-template-columns: 1fr;
    }

    .df-row__actions,
    .df-sensitive-form,
    .df-sensitive-form--right,
    .df-page-foot,
    .df-page-foot form,
    .df-btn {
        width: 100%;
    }

    .df-row__actions,
    .df-sensitive-form {
        align-items: stretch;
    }

    .df-compact-input {
        max-width: none;
        width: 100%;
    }

    .df-qr-card {
        grid-template-columns: 1fr;
    }

    .df-qr {
        justify-self: center;
        max-width: 100%;
    }

    .df-copy-row,
    .df-verify-block__entry {
        align-items: stretch;
        flex-direction: column;
    }

    .df-otp {
        display: grid;
        gap: 0.375rem;
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .df-otp__cell {
        aspect-ratio: 52 / 60;
        flex-basis: auto;
        height: auto;
        width: auto;
    }

    .df-auth-links {
        flex-wrap: wrap;
    }

    .df-dialog-popup .factura-csp-dialog__actions,
    .df-dialog-popup .factura-csp-dialog__actions .df-btn {
        width: 100%;
    }

    .df-dialog-popup .factura-csp-dialog__actions {
        flex-direction: column-reverse;
    }
}

/* Pricing Cards */
.card-pricing {
    /* background-color: white; Removed to allow gradient classes */
    border-radius: 1.5rem;
    padding: 2rem;
    border: 1px solid var(--warm-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.card-pricing:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.price-tag {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.price-period {
    font-size: 1rem;
    opacity: 0.8;
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 2rem 0;
    width: 100%;
    text-align: left;
}

.pricing-features li {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.check-icon {
    color: #00A67E;
    margin-right: 0.75rem;
    font-size: 1.1rem;
}

.card-pricing-highlight .check-icon {
    color: white;
}

.btn-pricing {
    width: 100%;
    padding: 1rem;
    border-radius: 9999px;
    font-weight: 600;
    margin-top: auto;
    transition: all 0.2s;
}

.btn-pricing-outline {
    background-color: #F3F4F6;
    color: var(--text-primary);
    border: none;
}

.btn-pricing-outline:hover {
    background-color: #E5E7EB;
}

.btn-pricing-white {
    background-color: white;
    color: #00A67E;
    border: none;
}

.btn-pricing-white:hover {
    background-color: #F9FAFB;
    transform: scale(1.02);
}

/* Tables */
.table-custom {
    background-color: var(--warm-card);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 10px 15px -3px rgba(139, 168, 136, 0.05);
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.table-custom thead {
    background: var(--action-primary);
}

.table-custom th {
    color: white;
    font-weight: 600;
    padding: 1rem;
    text-align: left;
}

.table-custom td {
    padding: 1rem;
    border-bottom: 1px solid var(--warm-border);
    color: var(--text-primary);
}

.table-custom tbody tr:last-child td {
    border-bottom: none;
}

.table-custom tbody tr:hover {
    background-color: rgba(139, 168, 136, 0.05);
}

.table-custom .table-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* Global Action Buttons */
.btn-action {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: none;
    transition: all 0.2s ease;
    cursor: pointer;
    background: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    /* For anchor tags acting as buttons */
}

.btn-action:hover {
    transform: scale(1.05);
    text-decoration: none;
}

.btn-action-info {
    background-color: rgba(139, 168, 136, 0.2);
    color: var(--sage-green);
}

/* Password Guidance */
.password-guidance {
    background-color: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: 1rem;
    padding: 1rem;
    box-shadow: 0 10px 15px -3px rgba(139, 168, 136, 0.05);
    --password-guidance-accent: var(--strength-empty);
    --password-guidance-bar: linear-gradient(90deg, var(--strength-empty), var(--strength-empty));
}

.password-guidance__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.password-guidance__title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-primary);
    font-weight: 700;
}

.password-guidance__label {
    color: var(--password-guidance-accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.password-guidance__track {
    width: 100%;
    height: 0.5rem;
    border-radius: 9999px;
    background-color: rgba(90, 108, 109, 0.12);
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.password-guidance__bar {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: var(--password-guidance-bar);
    transition: width 0.25s ease, background 0.25s ease;
}

.password-guidance__hint {
    display: block;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.password-guidance__rules {
    display: grid;
    gap: 0.65rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.password-guidance__rule {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.password-guidance__rule-icon {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(168, 197, 218, 0.2);
    color: var(--soft-blue);
    font-size: 0.7rem;
    transition: all 0.2s ease;
}

.password-guidance__rule.is-valid {
    color: var(--text-primary);
}

.password-guidance__rule.is-valid .password-guidance__rule-icon {
    background: rgba(139, 168, 136, 0.2);
    color: var(--sage-green);
}

@media (max-width: 576px) {
    .password-guidance__header {
        flex-direction: column;
        align-items: flex-start;
    }
}

.btn-action-info:hover {
    color: var(--sage-green);
    background-color: rgba(139, 168, 136, 0.3);
}

.btn-action-edit {
    background-color: rgba(168, 197, 218, 0.2);
    color: var(--soft-blue);
}

.btn-action-edit:hover {
    color: var(--soft-blue);
    background-color: rgba(168, 197, 218, 0.3);
}

.btn-action-delete {
    background-color: rgba(244, 168, 159, 0.2);
    color: var(--warm-coral);
}

.btn-action-delete:hover {
    color: var(--warm-coral);
    background-color: rgba(244, 168, 159, 0.3);
}

.btn-action-secondary {
    background-color: #E2E8F0;
    color: #718096;
}

.btn-action-secondary:hover {
    background-color: #CBD5E0;
    color: #4A5568;
}

/* Updates to table to use the global classes if they are still nested in HTML, 
   but we can remove the specific definitions here since they are now global */
/* .table-custom .btn-action inherits global styles */

/* Tabs */
.nav-tabs-custom {
    border-bottom: 2px solid var(--warm-border);
    gap: 0.5rem;
    padding-bottom: 1px;
    margin-bottom: 1.5rem;
}

.nav-tabs-custom .nav-item {
    margin-bottom: -2px;
}

.nav-tabs-custom .nav-link {
    border: none;
    color: var(--text-secondary);
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem 0.75rem 0 0;
    transition: all 0.3s ease;
    background: transparent;
    border-bottom: 3px solid transparent;
}

.nav-tabs-custom .nav-link:hover {
    color: var(--sage-green);
    background-color: rgba(139, 168, 136, 0.05);
}

.nav-tabs-custom .nav-link.active {
    color: var(--sage-green);
    background-color: white;
    border-bottom: 3px solid var(--sage-green);
    font-weight: 700;
}

.tab-pane-placeholder {
    padding: 3rem;
    text-align: center;
    background: white;
    border-radius: 1.5rem;
    border: 2px dashed var(--warm-border);
}

/* Timeline Component */
.timeline {
    position: relative;
    padding: 1rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 1.5rem;
    width: 2px;
    background: var(--warm-border);
    z-index: 0;
}

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
    padding-left: 4rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-icon {
    position: absolute;
    left: 0;
    top: 0;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    background-color: white;
    border: 2px solid var(--warm-border);
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.timeline-item:hover .timeline-icon {
    transform: scale(1.1);
    border-color: var(--sage-green);
}

.timeline-content {
    background-color: white;
    border: 1px solid var(--warm-border);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
}

.timeline-content:hover {
    box-shadow: 0 10px 15px -3px rgba(139, 168, 136, 0.05);
    transform: translateX(5px);
    border-color: var(--sage-green);
}

.timeline-date {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 0.25rem;
    display: block;
}

.timeline-title {
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

/* Timeline Icon Variants */
.timeline-icon.type-cita {
    color: var(--soft-blue);
    background-color: rgba(168, 197, 218, 0.1);
    border-color: var(--soft-blue);
}

.timeline-icon.type-doc {
    color: var(--sage-green);
    background-color: rgba(139, 168, 136, 0.1);
    border-color: var(--sage-green);
}

.timeline-icon.type-sesion {
    color: var(--warm-coral);
    background-color: rgba(244, 168, 159, 0.1);
    border-color: var(--warm-coral);
}

.timeline-icon.type-llamada {
    color: #A0AEC0;
    background-color: rgba(160, 174, 192, 0.1);
    border-color: #A0AEC0;
}

.timeline-icon.type-mensaje {
    color: #9F7AEA;
    /* Purple for messages */
    background-color: rgba(159, 122, 234, 0.1);
    border-color: #9F7AEA;
}

.timeline-icon.type-cuestionario {
    color: var(--soft-blue);
    background-color: rgba(168, 197, 218, 0.15);
    border-color: var(--soft-blue);
}

/* Chat Styles */
.chat-container {
    background-color: var(--warm-bg);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid var(--warm-border);
}

.chat-msg {
    display: flex;
    margin-bottom: 1rem;
    flex-direction: column;
}

.chat-msg.me {
    align-items: flex-end;
}

.chat-msg.other {
    align-items: flex-start;
}

.chat-bubble {
    padding: 0.75rem 1.25rem;
    border-radius: 1rem;
    max-width: 80%;
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    font-family: 'DM Sans', sans-serif;
}

.chat-msg.me .chat-bubble {
    background: var(--sage-green);
    color: white;
    border-bottom-right-radius: 0.25rem;
}

.chat-msg.other .chat-bubble {
    background: white;
    border: 1px solid var(--warm-border);
    color: var(--text-primary);
    border-bottom-left-radius: 0.25rem;
}

.chat-info {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    padding: 0 0.5rem;
}

.chat-date-separator {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.chat-date-separator span {
    background: rgba(168, 197, 218, 0.2);
    padding: 0.25rem 1rem;
    border-radius: 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
}

/* Chat Input Container */
.chat-input-container {
    background: var(--warm-card);
    border-radius: 1rem;
    padding: 1rem;
    border: 1px solid var(--warm-border);
}

.chat-input-container .input-group {
    display: flex;
    align-items: stretch;
}

.chat-input-container .form-control-custom {
    border: 1px solid var(--warm-border);
    background: white;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.chat-input-container .form-control-custom:focus {
    border-color: var(--sage-green);
    box-shadow: 0 0 0 3px rgba(139, 168, 136, 0.1);
    outline: none;
}

.chat-input-container .btn-gradient-primary {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    white-space: nowrap;
}

/* Timeline Expandable Content */
.timeline-expandable {
    margin-top: 0.5rem;
    padding-top: 0;
    border-top: none;
    display: none;
}

.timeline-expandable.show {
    display: block;
    animation: fadeInTimeline 0.3s ease;
}

.timeline-extra-info {
    background: linear-gradient(135deg, rgba(139, 168, 136, 0.08), rgba(168, 197, 218, 0.08));
    border: 1px solid rgba(139, 168, 136, 0.15);
    border-radius: 0.75rem;
    padding: 1rem;
    font-size: 0.9rem;
    color: var(--text-primary);
    position: relative;
    line-height: 1.5;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.02);
}

.timeline-notes-content {
    white-space: pre-wrap;
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.timeline-toggle-btn {
    background: none;
    border: none;
    padding: 0.35rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    border-radius: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.8rem;
}

.timeline-toggle-btn:hover {
    color: var(--sage-green);
    background: rgba(139, 168, 136, 0.1);
}

.timeline-toggle-btn.has-content {
    color: var(--sage-green);
}

.timeline-indicators {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    margin-top: 0.5rem;
}

.timeline-indicator-badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 0.35rem;
    background: rgba(139, 168, 136, 0.15);
    color: var(--sage-green);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.timeline-indicator-badge.timeline-indicator-pinned {
    background: rgba(168, 197, 218, 0.2);
    color: var(--soft-blue);
    cursor: default;
    transition: all 0.2s ease;
    padding-right: 0.35rem;
}

.timeline-indicator-badge.timeline-indicator-pinned:hover {
    background: rgba(168, 197, 218, 0.35);
}

/* Remove button inside pin badge */
.timeline-pin-remove-btn {
    background: none;
    border: none;
    padding: 0;
    margin-left: 0.35rem;
    cursor: pointer;
    color: var(--soft-blue);
    opacity: 0.6;
    font-size: 0.65rem;
    line-height: 1;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    border-radius: 50%;
}

.timeline-pin-remove-btn:hover {
    opacity: 1;
    background: rgba(244, 168, 159, 0.3);
    color: var(--warm-coral);
}

@keyframes fadeInTimeline {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Preview Panel */
.preview-panel {
    position: sticky;
    top: 8rem;
    background: var(--warm-bg);
    padding: 2rem;
    border-radius: 1.5rem;
    border: 1px solid var(--warm-border);
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
}

.preview-panel h3 {
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    font-size: var(--h4-size);
}

.preview-content {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
}

.preview-field {
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    margin: 0.5rem 0;
    border: 1px solid var(--warm-border);
    font-weight: 500;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.preview-field:hover {
    border-color: var(--sage-green);
    box-shadow: 0 4px 6px -1px rgba(139, 168, 136, 0.1);
}

.preview-signature {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: white;
    border-radius: 1rem;
    border: 2px dashed var(--warm-border);
    text-align: center;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-signature img {
    max-width: 100%;
    height: auto;
    max-height: 120px;
}

/* Signature Pad */
.signature-surface {
    width: 100%;
}

.signature-wrapper {
    width: 100%;
    max-width: 500px;
    height: 200px;
    border: 2px solid var(--warm-border);
    border-radius: 1rem;
    background: white;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.signature-wrapper canvas {
    display: block;
    width: 100%;
    height: 200px;
}

.signature-wrapper:hover {
    border-color: var(--sage-green);
    box-shadow: 0 0 0 3px rgba(139, 168, 136, 0.1);
}

/* Progress Steps */
.progress-steps-paneles {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3rem;
    position: relative;
    padding: 0 1rem;
}

.progress-steps-paneles::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 2rem;
    right: 2rem;
    height: 2px;
    background: var(--warm-border);
    z-index: 0;
}

.progress-line-paneles {
    position: absolute;
    top: 20px;
    left: 2rem;
    height: 2px;
    background: var(--sage-green);
    transition: width 0.3s ease;
    z-index: 1;
}

.progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 2;
}

.progress-step-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: white;
    border: 2px solid var(--warm-border);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.progress-step.active .progress-step-circle {
    background: var(--sage-green);
    color: white;
    border-color: var(--sage-green);
    box-shadow: 0 0 0 4px rgba(139, 168, 136, 0.2);
    transform: scale(1.1);
}

.progress-step.completed .progress-step-circle {
    background: var(--sage-green);
    border-color: var(--sage-green);
    color: white;
}

.progress-step-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
    transition: all 0.3s ease;
}

.progress-step.active .progress-step-label {
    color: var(--sage-green);
    font-weight: 700;
}

/* Animations */
.step {
    display: none;
}

.step.active {
    display: block;
    animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Custom Checkbox Group */
.checkbox-group {
    display: flex;
    align-items: center;
    padding: 1.25rem;
    background: var(--warm-bg);
    border-radius: 1rem;
    border: 2px solid var(--warm-border);
    cursor: pointer;
    transition: all 0.2s ease;
}

.checkbox-group:hover {
    border-color: var(--sage-green);
    background: white;
    box-shadow: 0 4px 6px -1px rgba(139, 168, 136, 0.05);
}

.checkbox-group input[type="checkbox"] {
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 1rem;
    cursor: pointer;
    accent-color: var(--sage-green);
}

.checkbox-group label {
    margin: 0;
    cursor: pointer;
    flex: 1;
    color: var(--text-primary);
    font-weight: 500;
}

.button-group-responsive {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

/* Report List & Detail */
.report-list-item {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.25s ease;
}

.report-list-item:hover {
    border-color: var(--sage-green);
    box-shadow: 0 4px 8px rgba(139, 168, 136, 0.1);
    transform: translateX(3px);
}

.report-list-item.active {
    background: linear-gradient(135deg, rgba(139, 168, 136, 0.12), rgba(168, 197, 218, 0.08));
    border-color: var(--sage-green);
    box-shadow: 0 2px 6px rgba(139, 168, 136, 0.15);
}

.report-list-item .report-list-date {
    font-size: 0.78rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 0.15rem;
}

.report-list-item .report-list-preview {
    font-size: 0.85rem;
    color: var(--text-primary);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.report-detail-panel {
    background: var(--warm-bg);
    border-radius: 1rem;
    border: 1px solid var(--warm-border);
    padding: 1.25rem;
}

.report-detail-content {
    background: var(--warm-card);
    border-radius: 0.75rem;
    border: 1px solid var(--warm-border);
    padding: 1.25rem;
    min-height: 180px;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-primary);
}

/* Quill table module rendered output */
.report-detail-content .ql-table-wrapper {
    width: 100%;
    overflow: auto;
}
.report-detail-content .ql-table {
    border-collapse: collapse;
    table-layout: fixed;
    width: 100%;
}
.report-detail-content .ql-table-cell {
    padding: 0.5rem 0.75rem;
    border: 1px solid #a1a1aa;
    font-size: 0.875rem;
    overflow: visible;
    overflow-wrap: anywhere;
}
/* Standard HTML tables */
.report-detail-content table:not(.ql-table) {
    width: 100%;
    border-collapse: collapse;
}
.report-detail-content table:not(.ql-table) td,
.report-detail-content table:not(.ql-table) th {
    border: 1px solid #a1a1aa;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
}

.report-detail-content [data-report-field="long-text"]:not([data-display-mode="inline"]),
.report-detail-content .report-answer-field:not(.report-answer-block):not(.report-answer-inline),
.ql-editor [data-report-field="long-text"]:not([data-display-mode="inline"]),
.report-field.report-field-long:not([data-display-mode="inline"]) {
    display: block;
    position: relative;
    min-height: 8.5rem;
    margin: 1rem 0;
    padding: 2.35rem 1rem 1rem;
    border: 2px dashed rgba(106, 171, 126, 0.45);
    border-radius: 0.9rem;
    background:
        linear-gradient(180deg, rgba(106, 171, 126, 0.08), rgba(106, 171, 126, 0.03)),
        repeating-linear-gradient(
            180deg,
            transparent 0,
            transparent 1.85rem,
            rgba(148, 163, 184, 0.28) 1.85rem,
            rgba(148, 163, 184, 0.28) 1.92rem
        );
}

.report-detail-content [data-report-field="long-text"]:not([data-display-mode="inline"])::before,
.report-detail-content .report-answer-field:not(.report-answer-block):not(.report-answer-inline)::before,
.ql-editor [data-report-field="long-text"]:not([data-display-mode="inline"])::before,
.report-field.report-field-long:not([data-display-mode="inline"])::before {
    content: attr(data-label);
    position: absolute;
    top: 0.7rem;
    left: 0.95rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--sage-green);
}

.report-detail-content [data-report-field="long-text"]:not([data-display-mode="inline"])::after,
.report-detail-content .report-answer-field:not(.report-answer-block):not(.report-answer-inline)::after,
.ql-editor [data-report-field="long-text"]:not([data-display-mode="inline"])::after,
.report-field.report-field-long:not([data-display-mode="inline"])::after {
    content: attr(data-placeholder);
    position: absolute;
    right: 0.95rem;
    bottom: 0.7rem;
    font-size: 0.72rem;
    color: var(--text-secondary);
    opacity: 0.7;
}

.report-detail-content [data-report-field="long-text"]:not([data-display-mode="inline"]):empty::before,
.report-detail-content .report-answer-field:not(.report-answer-block):not(.report-answer-inline):empty::before,
.ql-editor [data-report-field="long-text"]:not([data-display-mode="inline"]):empty::before,
.report-field.report-field-long:not([data-display-mode="inline"]):empty::before {
    content: attr(data-label);
}

.report-detail-content [data-report-field="long-text"][data-display-mode="inline"],
.report-detail-content .report-answer-inline,
.ql-editor [data-report-field="long-text"][data-display-mode="inline"] {
    display: inline-block;
    vertical-align: baseline;
    min-width: 12rem;
    min-height: 2.2rem;
    max-width: 100%;
    margin: 0 0.2rem;
    padding: 0.25rem 0.55rem 0.3rem;
    border-bottom: 2px dashed rgba(106, 171, 126, 0.55);
    border-radius: 0.45rem 0.45rem 0.2rem 0.2rem;
    background: rgba(106, 171, 126, 0.08);
    color: var(--text-primary);
    line-height: 1.55;
    white-space: normal;
    word-break: break-word;
}

.report-detail-content [data-report-field="long-text"][data-display-mode="inline"]:empty::before,
.ql-editor [data-report-field="long-text"][data-display-mode="inline"]:empty::before {
    content: "[" attr(data-placeholder) "]";
    color: var(--text-secondary);
    opacity: 0.82;
}

.report-detail-content .report-answer-inline:empty::before {
    content: "[" attr(data-label) "]";
    color: var(--text-secondary);
    opacity: 0.82;
}

.report-field-insert-help {
    border: 1px dashed var(--warm-border);
    border-radius: 0.85rem;
    padding: 0.85rem 1rem;
    background: rgba(255, 255, 255, 0.75);
    margin-bottom: 1rem;
}

.report-field-insert-help code {
    white-space: normal;
    word-break: break-word;
}

.report-field-insert-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.report-detail-content img,
.ql-editor img,
.report-editor-wrap img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 1rem 0;
    border-radius: 0.75rem;
}

.report-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.report-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.report-meta-item i {
    font-size: 0.75rem;
    opacity: 0.7;
}

.report-empty-state {
    padding: 2.5rem 1.5rem;
    text-align: center;
    background: white;
    border-radius: 1rem;
    border: 2px dashed var(--warm-border);
}

.report-empty-state i {
    font-size: 2rem;
    color: var(--action-primary);
    margin-bottom: 0.75rem;
    display: block;
}

.report-empty-state p {
    color: var(--text-secondary);
    margin: 0;
    font-size: 0.9rem;
}

.report-editor-wrap {
    background: var(--warm-bg);
    border-radius: 1rem;
    border: 1px solid var(--warm-border);
    padding: 1.25rem;
}

.report-editor-wrap .ql-container {
    border-radius: 0 0 0.5rem 0.5rem;
}

.report-editor-wrap .ql-toolbar {
    border-radius: 0.5rem 0.5rem 0 0;
    background: white;
}

.report-editor-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

@media (max-width: 768px) {
    .preview-panel {
        position: static;
        max-height: none;
        margin-top: 2rem;
        top: 0;
    }

    .button-group-responsive {
        flex-direction: column;
    }

    .button-group-responsive .btn {
        width: 100%;
    }

    .report-meta {
        flex-direction: column;
        gap: 0.25rem;
    }
}

/* Modal Custom */
.modal-custom {
    background-color: white !important;
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-custom .modal-header {
    background-color: white !important;
    border-bottom: 1px solid var(--warm-border);
    padding: 1.25rem 1.5rem;
}

.modal-custom .modal-body {
    background-color: white !important;
}

.modal-custom .modal-footer {
    background-color: white !important;
    border-top: 1px solid var(--warm-border);
}

/* Template Picker */
.template-picker-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 60vh;
    overflow-y: auto;
    padding: 0.25rem 0.25rem;
}

.template-picker-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: white !important;
    border: 2px solid var(--warm-border);
    border-radius: 0.875rem;
    cursor: pointer;
    transition: all 0.25s ease;
    margin: 0;
    position: relative;
}

.template-picker-item:hover {
    border-color: var(--sage-green);
    box-shadow: 0 4px 12px rgba(139, 168, 136, 0.12);
    transform: translateX(2px);
}

/* Ocultar el radio nativo */
.template-picker-item input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

/* Estado seleccionado */
.template-picker-item:has(input[type="radio"]:checked) {
    border-color: var(--sage-green);
    background: linear-gradient(135deg, rgba(139, 168, 136, 0.08), rgba(168, 197, 218, 0.05));
    box-shadow: 0 2px 8px rgba(139, 168, 136, 0.18);
}

.template-picker-item-body {
    flex: 1;
    min-width: 0;
}

.template-picker-item-title {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 0.2rem;
    line-height: 1.3;
}

.template-picker-item-desc {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.template-picker-item-preview {
    font-size: 0.8rem;
    color: var(--text-secondary);
    opacity: 0.75;
    margin-top: 0.35rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Check visual - oculto por defecto */
.template-picker-item-check {
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    border: 2px solid var(--warm-border);
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.25s ease;
    color: white;
    font-size: 0.75rem;
}

.template-picker-item:has(input[type="radio"]:checked) .template-picker-item-check {
    background: var(--sage-green);
    border-color: var(--sage-green);
    box-shadow: 0 0 0 3px rgba(139, 168, 136, 0.2);
}

@media (prefers-reduced-motion: reduce) {
    .btn-gradient-primary,
    .btn-outline-custom,
    .btn-outline-custom-sm,
    .btn-action,
    .card-custom,
    .icon-box-custom,
    .form-control-custom,
    .template-picker-item,
    .template-picker-item-check {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transform: none !important;
    }
}
