.qr-interest-scanner-container {
    --qr-interest-blue: #02109f;
    --qr-interest-yellow: #ffd900;
    --qr-interest-dark: #111827;
    --qr-interest-muted: #6b7280;
    --qr-interest-border: #e5e7eb;
    --qr-interest-bg: #f8fafc;
    font-family: Arial, sans-serif;
    color: var(--qr-interest-dark);
    isolation: isolate;
}

.qr-interest-shell {
    max-width: 1120px;
    margin: 0 auto;
    padding: 24px;
}

.qr-interest-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    background: linear-gradient(135deg, var(--qr-interest-blue), #005c9f);
    color: #fff;
    border-radius: 24px;
    padding: 28px;
    margin-bottom: 20px;
    box-shadow: 0 18px 50px rgba(2, 16, 159, .18);
}

.qr-interest-kicker {
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: .12em;
    opacity: .8;
    margin-bottom: 8px;
}

.qr-interest-header h2 {
    margin: 0 0 8px;
    font-size: clamp(26px, 4vw, 42px);
    line-height: 1.05;
    color: #fff;
}

.qr-interest-header p {
    margin: 0;
    color: rgba(255,255,255,.86);
}

.qr-interest-shortcode-badge {
    width: 64px;
    height: 64px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    background: rgba(255,255,255,.12);
    font-size: 28px;
}

.qr-interest-card,
.qr-interest-session-card {
    background: #fff;
    border: 1px solid var(--qr-interest-border);
    border-radius: 22px;
    padding: 24px;
    box-shadow: 0 12px 38px rgba(15, 23, 42, .08);
}

.qr-interest-login-card {
    max-width: 760px;
    margin: 0 auto;
}

.qr-interest-login-card h3,
.qr-interest-result-panel h3 {
    margin-top: 0;
}

.qr-interest-muted {
    color: var(--qr-interest-muted);
}

.qr-interest-grid.two-cols {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.qr-interest-field {
    margin-bottom: 16px;
    position: relative;
}

.qr-interest-field label {
    display: block;
    font-weight: 700;
    margin-bottom: 7px;
}

.qr-interest-field input {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    min-height: 46px;
    padding: 10px 13px;
    font-size: 16px;
    background: #fff;
}

.qr-interest-field input:focus {
    outline: 3px solid rgba(2, 16, 159, .12);
    border-color: var(--qr-interest-blue);
}

.qr-interest-product-results {
    position: absolute;
    z-index: 10;
    top: calc(100% - 6px);
    left: 0;
    right: 0;
    max-height: 320px;
    overflow: auto;
    background: #fff;
    border: 1px solid var(--qr-interest-border);
    border-radius: 14px;
    box-shadow: 0 20px 50px rgba(15, 23, 42, .18);
    display: none;
}

.qr-interest-product-option {
    display: block;
    width: 100%;
    text-align: left;
    border: 0;
    background: #fff;
    padding: 12px 14px;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
}

.qr-interest-product-option:hover {
    background: #f8fafc;
}

.qr-interest-product-option span,
.qr-interest-product-option small {
    display: block;
}

.qr-interest-product-option small {
    color: var(--qr-interest-muted);
    margin-top: 3px;
}

.qr-interest-result-empty,
.qr-interest-selected-product {
    padding: 12px 14px;
    color: var(--qr-interest-muted);
}

.qr-interest-selected-product {
    margin-top: 8px;
    border-radius: 12px;
    background: #ecfdf5;
    color: #166534;
}

.qr-interest-btn {
    border: 0;
    border-radius: 12px;
    padding: 12px 18px;
    min-height: 44px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.qr-interest-btn:disabled {
    opacity: .7;
    cursor: not-allowed;
}

.qr-interest-btn-primary {
    background: var(--qr-interest-blue);
    color: #fff;
}

.qr-interest-btn-secondary {
    background: #f1f5f9;
    color: #0f172a;
}

.qr-interest-message {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 12px;
    font-weight: 700;
}

.qr-interest-message.is-error {
    background: #fef2f2;
    color: #991b1b;
}

.qr-interest-message.is-success {
    background: #ecfdf5;
    color: #166534;
}

.qr-interest-message.is-info {
    background: #eff6ff;
    color: #1d4ed8;
}

.qr-interest-session-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.qr-interest-session-info span,
.qr-interest-session-info small {
    display: block;
    color: var(--qr-interest-muted);
}

.qr-interest-session-info strong {
    display: block;
    font-size: 18px;
}

.qr-interest-scanner-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
    gap: 22px;
    align-items: stretch;
}

.qr-interest-status {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    font-weight: 700;
}

.qr-interest-status-loading {
    background: #fffbeb;
    color: #92400e;
}

.qr-interest-status-ready {
    background: #ecfdf5;
    color: #166534;
}

.qr-interest-status-error {
    background: #fef2f2;
    color: #991b1b;
}

.qr-interest-video-wrap {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    background: #000;
    aspect-ratio: 1 / 1;
}

.qr-interest-video-wrap video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.qr-interest-scan-overlay {
    position: absolute;
    inset: 12%;
    pointer-events: none;
}

.qr-interest-scan-overlay span {
    position: absolute;
    width: 44px;
    height: 44px;
    border-color: var(--qr-interest-yellow);
    border-style: solid;
}

.qr-interest-scan-overlay span:nth-child(1) { top: 0; left: 0; border-width: 4px 0 0 4px; }
.qr-interest-scan-overlay span:nth-child(2) { top: 0; right: 0; border-width: 4px 4px 0 0; }
.qr-interest-scan-overlay span:nth-child(3) { bottom: 0; left: 0; border-width: 0 0 4px 4px; }
.qr-interest-scan-overlay span:nth-child(4) { bottom: 0; right: 0; border-width: 0 4px 4px 0; }

.qr-interest-camera-actions {
    margin-top: 12px;
}

.qr-interest-result-panel {
    min-height: 100%;
    border: 1px dashed #cbd5e1;
    border-radius: 20px;
    padding: 24px;
    display: grid;
    align-items: center;
    text-align: center;
    background: var(--qr-interest-bg);
}

.qr-interest-result-panel > div > i {
    font-size: 44px;
    margin-bottom: 12px;
    color: var(--qr-interest-blue);
}

.qr-interest-success-state > i {
    color: #16a34a !important;
}

.qr-interest-error-state > i {
    color: #dc2626 !important;
}

.qr-interest-mini-table {
    text-align: left;
    display: grid;
    gap: 10px;
    margin: 14px 0;
}

.qr-interest-mini-table div {
    background: #fff;
    border: 1px solid var(--qr-interest-border);
    border-radius: 12px;
    padding: 10px 12px;
}

.qr-interest-mini-table span {
    display: block;
    color: var(--qr-interest-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.qr-interest-mini-table strong {
    display: block;
    margin-top: 3px;
}

.qr-interest-success-message {
    color: #166534;
    font-weight: 700;
}

@media (max-width: 860px) {
    .qr-interest-shell {
        padding: 14px;
    }

    .qr-interest-header,
    .qr-interest-session-card {
        flex-direction: column;
        align-items: stretch;
    }

    .qr-interest-grid.two-cols,
    .qr-interest-scanner-layout {
        grid-template-columns: 1fr;
    }
}

/* Ajustes v1.1: selector de carreras y resultado manual */
.qr-interest-scanner-container .qr-interest-product-results {
    z-index: 999999 !important;
    max-height: 360px;
    padding: 6px;
}

.qr-interest-scanner-container .qr-interest-product-option {
    appearance: none !important;
    -webkit-appearance: none !important;
    display: block !important;
    width: 100% !important;
    min-height: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 12px 14px !important;
    border: 0 !important;
    border-bottom: 1px solid #e5e7eb !important;
    border-radius: 10px !important;
    background: #fff !important;
    color: #111827 !important;
    text-align: left !important;
    font-size: 15px !important;
    line-height: 1.35 !important;
    font-weight: 600 !important;
    text-transform: none !important;
    letter-spacing: normal !important;
    cursor: pointer !important;
    box-shadow: none !important;
    white-space: normal !important;
}

.qr-interest-scanner-container .qr-interest-product-option:hover,
.qr-interest-scanner-container .qr-interest-product-option:focus {
    background: #eff6ff !important;
    color: #02109f !important;
    outline: 2px solid rgba(2, 16, 159, .18) !important;
}

.qr-interest-scanner-container .qr-interest-product-option span,
.qr-interest-scanner-container .qr-interest-product-option small {
    display: block !important;
    width: 100% !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}

.qr-interest-scanner-container .qr-interest-product-option small {
    margin-top: 4px !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    text-transform: none !important;
}

.qr-interest-scanner-container .qr-interest-selected-product {
    display: none !important;
}

.qr-interest-scanner-container .qr-interest-success-state,
.qr-interest-scanner-container .qr-interest-error-state {
    align-self: start;
}

.qr-interest-scanner-container .qr-interest-result-content {
    max-height: none;
}

.qr-interest-scanner-container .qr-interest-toast {
    position: fixed;
    left: 50%;
    top: 18px;
    z-index: 1000000;
    transform: translate(-50%, -18px);
    opacity: 0;
    max-width: min(520px, calc(100vw - 32px));
    padding: 14px 18px;
    border-radius: 14px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, .22);
    font-weight: 800;
    text-align: center;
    transition: opacity .2s ease, transform .2s ease;
}

.qr-interest-scanner-container .qr-interest-toast.is-visible {
    opacity: 1;
    transform: translate(-50%, 0);
}

.qr-interest-scanner-container .qr-interest-toast.is-success {
    background: #ecfdf5;
    color: #166534;
    border: 1px solid #bbf7d0;
}

@media (max-width: 860px) {
    .qr-interest-scanner-container .qr-interest-product-results {
        position: static;
        margin-top: 8px;
        max-height: 300px;
    }

    .qr-interest-scanner-container .qr-interest-product-option {
        font-size: 14px !important;
        padding: 11px 12px !important;
    }
}

/* Ajustes v1.1.3: separacion con footer, dashboard publico y mensajes limpios */
.qr-interest-scanner-container .qr-interest-shell {
    padding-bottom: 72px;
}

.qr-interest-scanner-container .qr-interest-login-card,
.qr-interest-scanner-container .qr-interest-scanner-card {
    margin-bottom: 56px;
}

.qr-interest-dashboard-container {
    --qr-interest-blue: #02109f;
    --qr-interest-dark: #111827;
    --qr-interest-muted: #6b7280;
    --qr-interest-border: #e5e7eb;
    --qr-interest-bg: #f8fafc;
    font-family: Arial, sans-serif;
    color: var(--qr-interest-dark);
    isolation: isolate;
}

.qr-interest-dashboard-shell {
    max-width: 1220px;
    margin: 0 auto;
    padding: 24px 24px 80px;
}

.qr-interest-dashboard-hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    padding: 30px;
    border-radius: 24px;
    color: #fff;
    background: linear-gradient(135deg, #02109f, #006699);
    box-shadow: 0 18px 50px rgba(2, 16, 159, .18);
    margin-bottom: 20px;
}

.qr-interest-dashboard-hero span {
    display: block;
    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
    opacity: .82;
    margin-bottom: 8px;
}

.qr-interest-dashboard-hero h2 {
    margin: 0 0 8px;
    color: #fff;
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.05;
}

.qr-interest-dashboard-hero p {
    margin: 0;
    color: rgba(255,255,255,.86);
}

.qr-interest-dashboard-logout {
    border: 1px solid rgba(255,255,255,.45);
    background: rgba(255,255,255,.12);
    color: #fff;
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 700;
    cursor: pointer;
}

.qr-interest-dashboard-login-card,
.qr-interest-dashboard-card,
.qr-interest-dashboard-toolbar,
.qr-interest-dashboard-metrics article {
    background: #fff;
    border: 1px solid var(--qr-interest-border);
    border-radius: 20px;
    box-shadow: 0 12px 34px rgba(15, 23, 42, .07);
}

.qr-interest-dashboard-login-card {
    max-width: 620px;
    margin: 0 auto 56px;
    padding: 26px;
}

.qr-interest-dashboard-login-card h3,
.qr-interest-dashboard-card h3 {
    margin-top: 0;
}

.qr-interest-dashboard-login-form label span {
    display: block;
    font-weight: 700;
    margin-bottom: 7px;
}

.qr-interest-dashboard-login-form input,
.qr-interest-dashboard-toolbar select {
    width: 100%;
    min-height: 46px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 10px 13px;
    font-size: 16px;
    background: #fff;
}

.qr-interest-dashboard-login-form button {
    margin-top: 14px;
}

.qr-interest-access-note {
    margin-bottom: 0;
    color: var(--qr-interest-muted);
}

.qr-interest-dashboard-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 18px;
    margin-bottom: 18px;
}

.qr-interest-dashboard-toolbar form {
    min-width: min(420px, 100%);
}

.qr-interest-dashboard-toolbar label span {
    display: block;
    font-weight: 700;
    margin-bottom: 6px;
}

.qr-interest-dashboard-user {
    color: var(--qr-interest-muted);
}

.qr-interest-dashboard-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.qr-interest-dashboard-metrics article {
    padding: 20px;
}

.qr-interest-dashboard-metrics span {
    display: block;
    color: #64748b;
    font-weight: 700;
}

.qr-interest-dashboard-metrics strong {
    display: block;
    margin-top: 6px;
    color: var(--qr-interest-blue);
    font-size: 34px;
    line-height: 1;
}

.qr-interest-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
    gap: 18px;
    margin-bottom: 18px;
}

.qr-interest-dashboard-card {
    padding: 22px;
}

.qr-interest-bars {
    display: grid;
    gap: 14px;
}

.qr-interest-bar-label {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-end;
    margin-bottom: 7px;
}

.qr-interest-bar-label strong {
    display: block;
}

.qr-interest-bar-label span {
    color: var(--qr-interest-muted);
    font-size: 13px;
    white-space: nowrap;
}

.qr-interest-bar-track {
    height: 13px;
    border-radius: 999px;
    overflow: hidden;
    background: #e5e7eb;
}

.qr-interest-bar-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #02109f, #006699);
}

.qr-interest-personnel-list {
    display: grid;
    gap: 12px;
}

.qr-interest-personnel-list div {
    padding: 12px;
    border: 1px solid var(--qr-interest-border);
    border-radius: 14px;
    background: #f8fafc;
}

.qr-interest-personnel-list strong,
.qr-interest-personnel-list span,
.qr-interest-personnel-list small {
    display: block;
}

.qr-interest-personnel-list span,
.qr-interest-personnel-list small {
    color: var(--qr-interest-muted);
    margin-top: 3px;
}

.qr-interest-dashboard-table-wrap {
    width: 100%;
    overflow: auto;
}

.qr-interest-dashboard-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 780px;
}

.qr-interest-dashboard-table th,
.qr-interest-dashboard-table td {
    text-align: left;
    border-bottom: 1px solid var(--qr-interest-border);
    padding: 12px;
    vertical-align: top;
}

.qr-interest-dashboard-table th {
    color: #334155;
    background: #f8fafc;
}

@media (max-width: 900px) {
    .qr-interest-dashboard-shell {
        padding: 14px 14px 72px;
    }

    .qr-interest-dashboard-hero,
    .qr-interest-dashboard-toolbar,
    .qr-interest-bar-label {
        flex-direction: column;
        align-items: stretch;
    }

    .qr-interest-dashboard-metrics,
    .qr-interest-dashboard-grid {
        grid-template-columns: 1fr;
    }

    .qr-interest-bar-label span {
        white-space: normal;
    }
}

/* Ajustes v1.1.5: selector que no se superpone al footer y resumen ejecutivo del dashboard */
.qr-interest-scanner-container .qr-interest-field:has(.qr-interest-product-results) {
    margin-bottom: 24px;
}

.qr-interest-scanner-container .qr-interest-product-results {
    position: static !important;
    z-index: auto !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    margin-top: 8px !important;
    margin-bottom: 20px !important;
    max-height: 360px !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

.qr-interest-scanner-container .qr-interest-login-card {
    overflow: visible !important;
}

.qr-interest-scanner-container .qr-interest-btn-primary {
    margin-top: 4px;
}

.qr-interest-dashboard-insights {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.qr-interest-dashboard-insights article {
    background: #fff;
    border: 1px solid var(--qr-interest-border);
    border-radius: 20px;
    box-shadow: 0 12px 34px rgba(15, 23, 42, .07);
    padding: 18px;
    min-height: 132px;
}

.qr-interest-dashboard-insights span,
.qr-interest-dashboard-insights small {
    display: block;
    color: var(--qr-interest-muted);
}

.qr-interest-dashboard-insights span {
    font-weight: 800;
    margin-bottom: 9px;
}

.qr-interest-dashboard-insights strong {
    display: block;
    color: #111827;
    font-size: 18px;
    line-height: 1.25;
    margin-bottom: 8px;
    overflow-wrap: anywhere;
}

.qr-interest-dashboard-card-note {
    color: var(--qr-interest-muted);
    margin-top: -6px;
    margin-bottom: 18px;
}

@media (max-width: 1100px) {
    .qr-interest-dashboard-insights {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 700px) {
    .qr-interest-dashboard-insights {
        grid-template-columns: 1fr;
    }

    .qr-interest-scanner-container .qr-interest-product-results {
        max-height: 300px !important;
    }
}

/* Ajustes v1.1.7: filtros del dashboard publico */
.qr-interest-dashboard-toolbar {
    align-items: flex-start;
}

.qr-interest-dashboard-filters {
    display: grid;
    grid-template-columns: minmax(220px, 1.2fr) minmax(220px, 1fr) minmax(220px, 1fr) minmax(140px, .6fr) minmax(140px, .6fr) auto;
    gap: 12px;
    width: 100%;
}

.qr-interest-dashboard-filters label {
    min-width: 0;
}

.qr-interest-dashboard-login-form input,
.qr-interest-dashboard-toolbar select,
.qr-interest-dashboard-toolbar input[type="date"] {
    width: 100%;
    min-height: 46px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 10px 13px;
    font-size: 16px;
    background: #fff;
}

.qr-interest-dashboard-filter-actions {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    padding-bottom: 1px;
}

.qr-interest-dashboard-filter-actions a {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    color: #02109f;
    font-weight: 800;
    text-decoration: none;
}

@media (max-width: 1180px) {
    .qr-interest-dashboard-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 700px) {
    .qr-interest-dashboard-filters {
        grid-template-columns: 1fr;
    }

    .qr-interest-dashboard-filter-actions {
        align-items: stretch;
        flex-direction: column;
    }
}


/* Ajustes v1.1.8: scroll interno en dashboard y toolbar estable */
.qr-interest-dashboard-toolbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
    align-items: stretch;
}

.qr-interest-dashboard-user {
    justify-self: end;
    text-align: right;
}

.qr-interest-dashboard-grid {
    align-items: start;
}

.qr-interest-dashboard-card-large,
.qr-interest-dashboard-card {
    min-height: 0;
}

.qr-interest-bars,
.qr-interest-personnel-list {
    max-height: 460px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
}

.qr-interest-dashboard-table-wrap {
    max-height: 460px;
    overflow: auto;
}

.qr-interest-dashboard-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
}

.qr-interest-bars::-webkit-scrollbar,
.qr-interest-personnel-list::-webkit-scrollbar,
.qr-interest-dashboard-table-wrap::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.qr-interest-bars::-webkit-scrollbar-thumb,
.qr-interest-personnel-list::-webkit-scrollbar-thumb,
.qr-interest-dashboard-table-wrap::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 999px;
    border: 2px solid #fff;
}

.qr-interest-bars::-webkit-scrollbar-track,
.qr-interest-personnel-list::-webkit-scrollbar-track,
.qr-interest-dashboard-table-wrap::-webkit-scrollbar-track {
    background: #f8fafc;
    border-radius: 999px;
}

@media (max-width: 1180px) {
    .qr-interest-dashboard-user {
        justify-self: start;
        text-align: left;
    }
}

@media (max-width: 900px) {
    .qr-interest-bars,
    .qr-interest-personnel-list,
    .qr-interest-dashboard-table-wrap {
        max-height: 360px;
    }
}


/* Ajustes v1.1.9: boton de filtros sin cortes */
.qr-interest-dashboard-filters {
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    align-items: end;
}

.qr-interest-dashboard-filter-actions {
    width: 100%;
    min-width: 0;
}

.qr-interest-dashboard-filter-actions .qr-interest-btn {
    width: 100%;
    min-width: 132px;
    white-space: normal;
    line-height: 1.1;
    padding-left: 14px;
    padding-right: 14px;
}

.qr-interest-dashboard-filter-actions a {
    justify-content: center;
}

@media (min-width: 1100px) {
    .qr-interest-dashboard-filter-actions .qr-interest-btn {
        white-space: nowrap;
    }
}

@media (max-width: 700px) {
    .qr-interest-dashboard-filter-actions .qr-interest-btn {
        width: 100%;
    }
}


/* Ajustes v1.1.10: toolbar de filtros estable y sin deformar layout */
.qr-interest-dashboard-toolbar {
    display: block;
    padding: 18px;
}

.qr-interest-dashboard-user {
    display: block;
    width: 100%;
    margin: 0 0 14px;
    text-align: right;
    color: var(--qr-interest-muted);
}

.qr-interest-dashboard-filters {
    display: grid;
    grid-template-columns:
        minmax(190px, 1.15fr)
        minmax(190px, 1fr)
        minmax(190px, 1fr)
        minmax(138px, .62fr)
        minmax(138px, .62fr)
        minmax(180px, auto);
    gap: 12px;
    width: 100%;
    align-items: end;
}

.qr-interest-dashboard-filters label {
    min-width: 0;
}

.qr-interest-dashboard-filter-actions {
    display: flex;
    align-items: end;
    justify-content: flex-start;
    gap: 10px;
    width: 100%;
    min-width: 180px;
    padding-bottom: 0;
}

.qr-interest-dashboard-filter-actions .qr-interest-btn {
    width: auto;
    min-width: 148px;
    max-width: 100%;
    white-space: normal;
    line-height: 1.08;
    padding: 11px 16px;
    flex: 0 0 auto;
}

.qr-interest-dashboard-filter-actions a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    flex: 0 0 auto;
}

@media (max-width: 1250px) {
    .qr-interest-dashboard-filters {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .qr-interest-dashboard-filter-actions {
        min-width: 0;
    }
}

@media (max-width: 900px) {
    .qr-interest-dashboard-user {
        text-align: left;
    }

    .qr-interest-dashboard-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .qr-interest-dashboard-filters {
        grid-template-columns: 1fr;
    }

    .qr-interest-dashboard-filter-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .qr-interest-dashboard-filter-actions .qr-interest-btn,
    .qr-interest-dashboard-filter-actions a {
        width: 100%;
    }
}


/* Ajustes v1.1.11: proteger filtros contra wpautop del tema */
.qr-interest-dashboard-filters > p {
    display: contents !important;
    margin: 0 !important;
    padding: 0 !important;
}

.qr-interest-dashboard-filters br {
    display: none !important;
}

.qr-interest-dashboard-filters > label,
.qr-interest-dashboard-filters > p > label,
.qr-interest-dashboard-filter-actions {
    align-self: end;
}

.qr-interest-dashboard-filters > p > label {
    display: block;
    width: 100%;
}

.qr-interest-dashboard-toolbar > p {
    display: none !important;
    margin: 0 !important;
}

.qr-interest-dashboard-toolbar {
    gap: 12px;
}

.qr-interest-dashboard-user {
    margin-top: 14px;
}


/* Ajustes v1.1.12: proteger login del scanner contra wpautop del tema */
.qr-interest-scanner-container .qr-interest-login-form br,
.qr-interest-scanner-container .qr-interest-login-card br,
.qr-interest-scanner-container .qr-interest-product-field br {
    display: none !important;
}

.qr-interest-scanner-container .qr-interest-login-form > p,
.qr-interest-scanner-container .qr-interest-grid > p,
.qr-interest-scanner-container .qr-interest-field > p,
.qr-interest-scanner-container .qr-interest-product-field > p,
.qr-interest-scanner-container .qr-interest-login-card > p:empty {
    display: contents !important;
    margin: 0 !important;
    padding: 0 !important;
}

.qr-interest-scanner-container .qr-interest-login-form > p:empty,
.qr-interest-scanner-container .qr-interest-grid > p:empty,
.qr-interest-scanner-container .qr-interest-field > p:empty,
.qr-interest-scanner-container .qr-interest-product-field > p:empty {
    display: none !important;
}

.qr-interest-scanner-container .qr-interest-login-form .qr-interest-btn {
    margin-top: 4px;
}

.qr-interest-scanner-container .qr-interest-login-form > .qr-interest-message {
    margin-top: 14px;
}


/* Ajustes v1.1.13: proteger vista de sesion y scanner contra wpautop del tema */
.qr-interest-scanner-container .qr-interest-session-card br,
.qr-interest-scanner-container .qr-interest-scanner-card br,
.qr-interest-scanner-container .qr-interest-scanner-layout br,
.qr-interest-scanner-container .qr-interest-camera-panel br,
.qr-interest-scanner-container .qr-interest-video-wrap br,
.qr-interest-scanner-container .qr-interest-result-panel br {
    display: none !important;
}

.qr-interest-scanner-container .qr-interest-session-card > p,
.qr-interest-scanner-container .qr-interest-scanner-card > p,
.qr-interest-scanner-container .qr-interest-scanner-layout > p,
.qr-interest-scanner-container .qr-interest-camera-panel > p,
.qr-interest-scanner-container .qr-interest-video-wrap > p,
.qr-interest-scanner-container .qr-interest-result-panel > p,
.qr-interest-scanner-container .qr-interest-waiting-state > p:empty,
.qr-interest-scanner-container .qr-interest-processing-state > p:empty,
.qr-interest-scanner-container .qr-interest-success-state > p:empty,
.qr-interest-scanner-container .qr-interest-error-state > p:empty {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.qr-interest-scanner-container .qr-interest-session-card {
    align-items: stretch;
}

.qr-interest-scanner-container .qr-interest-session-info span,
.qr-interest-scanner-container .qr-interest-session-info strong,
.qr-interest-scanner-container .qr-interest-session-info small {
    margin-bottom: 6px;
}

.qr-interest-scanner-container .qr-interest-camera-panel,
.qr-interest-scanner-container .qr-interest-result-panel {
    min-width: 0;
    position: relative;
}

.qr-interest-scanner-container .qr-interest-result-panel {
    width: 100%;
    box-sizing: border-box;
}

.qr-interest-scanner-container .qr-interest-waiting-state,
.qr-interest-scanner-container .qr-interest-processing-state,
.qr-interest-scanner-container .qr-interest-success-state,
.qr-interest-scanner-container .qr-interest-error-state {
    width: 100%;
}

.qr-interest-scanner-container .qr-interest-success-state p,
.qr-interest-scanner-container .qr-interest-error-state p,
.qr-interest-scanner-container .qr-interest-processing-state p,
.qr-interest-scanner-container .qr-interest-waiting-state p {
    margin: 8px 0 0;
}

.qr-interest-scanner-container .qr-interest-success-state .qr-interest-btn,
.qr-interest-scanner-container .qr-interest-error-state .qr-interest-btn {
    margin-top: 16px;
}

@media (max-width: 960px) {
    .qr-interest-scanner-container .qr-interest-scanner-layout {
        display: flex !important;
        flex-direction: column !important;
        gap: 18px !important;
        align-items: stretch !important;
    }

    .qr-interest-scanner-container .qr-interest-camera-panel,
    .qr-interest-scanner-container .qr-interest-result-panel {
        width: 100% !important;
        max-width: 100% !important;
    }

    .qr-interest-scanner-container .qr-interest-result-panel {
        min-height: 240px;
        margin-top: 0 !important;
        z-index: 1;
    }

    .qr-interest-scanner-container .qr-interest-video-wrap {
        width: 100%;
        aspect-ratio: 1 / 1;
        z-index: 0;
    }
}

/* Ajustes v1.1.14: flujo rapido de escaneo y acciones de sesion */
.qr-interest-scanner-container .qr-interest-session-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.qr-interest-scanner-container .qr-interest-logout-btn {
    white-space: normal;
    text-align: center;
}

.qr-interest-scanner-container .qr-interest-auto-reset-note {
    margin-top: 12px;
    color: #64748b;
    font-weight: 700;
}

.qr-interest-scanner-container .qr-interest-login-form .qr-interest-btn.is-loading,
.qr-interest-scanner-container .qr-interest-logout-btn:disabled {
    opacity: .85;
    cursor: wait;
}

.qr-interest-scanner-container .qr-interest-login-form .qr-interest-message.is-info {
    display: block;
}

.qr-interest-fields-grid textarea[name="allowed_domain"] {
    width: 100%;
    min-height: 92px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
    resize: vertical;
}

@media (max-width: 860px) {
    .qr-interest-scanner-container .qr-interest-session-actions {
        justify-content: stretch;
    }

    .qr-interest-scanner-container .qr-interest-logout-btn {
        width: 100%;
    }
}


/* Ajustes v1.1.15: banner compacto en login y oculto con sesion activa */
.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact {
    padding: 18px 22px;
    margin-bottom: 18px;
    border-radius: 20px;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact h2 {
    font-size: clamp(24px, 3vw, 34px);
    margin-bottom: 0;
    line-height: 1.08;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-kicker {
    font-size: 11px;
    margin-bottom: 6px;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-shortcode-badge {
    width: 50px;
    height: 50px;
    border-radius: 15px;
    font-size: 22px;
}

.qr-interest-scanner-container.qr-interest-has-session .qr-interest-shell {
    padding-top: 24px;
}

@media (max-width: 700px) {
    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact {
        padding: 18px;
        align-items: flex-start;
    }

    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact h2 {
        font-size: 26px;
    }

    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-shortcode-badge {
        width: 46px;
        height: 46px;
        font-size: 20px;
    }
}


/* Ajustes v1.1.16: banner de login ultra compacto */
.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 14px !important;
    padding: 14px 18px !important;
    margin-bottom: 16px !important;
    min-height: auto !important;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact > p,
.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact br {
    display: none !important;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact h2 {
    white-space: nowrap !important;
    margin: 0 !important;
    font-size: clamp(22px, 3.2vw, 32px) !important;
    line-height: 1 !important;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-kicker {
    margin: 0 0 5px !important;
    font-size: 10px !important;
    line-height: 1 !important;
}

.qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-shortcode-badge {
    flex: 0 0 42px !important;
    width: 42px !important;
    height: 42px !important;
    border-radius: 13px !important;
    font-size: 18px !important;
}

@media (max-width: 700px) {
    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact {
        padding: 14px 16px !important;
        gap: 8px !important;
    }

    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact h2 {
        font-size: clamp(19px, 5.2vw, 22px) !important;
        letter-spacing: -0.03em !important;
    }

    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact .qr-interest-shortcode-badge {
        display: none !important;
    }
}

@media (max-width: 380px) {
    .qr-interest-scanner-container.qr-interest-login-view .qr-interest-header-compact h2 {
        font-size: 18px !important;
    }
}
