﻿/* =========================
   RINCON UI - COMMON STYLES
   ========================= */

.rincon-page,
.admin-page,
.cart-page {
    color: #1f2937;
}

/* HERO / HEADER */

.rincon-hero,
.admin-hero,
.cart-hero {
    background: linear-gradient(135deg, #f8fafc 0%, #eef6ff 100%);
    border: 1px solid #e5edf7;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.rincon-hero-icon,
.admin-hero-icon,
.cart-hero-icon,
.action-icon,
.checkout-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e8f1ff;
    color: #0d6efd;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.rincon-eyebrow,
.admin-eyebrow,
.cart-eyebrow,
.section-kicker {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #0d6efd;
    margin-bottom: 2px;
}

.rincon-title,
.admin-title,
.cart-title {
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #111827;
}

.rincon-subtitle,
.admin-subtitle,
.cart-subtitle,
.action-description,
.checkout-description {
    color: #6b7280;
}

/* CARDS */

.content-card,
.form-card,
.action-card,
.checkout-card,
.checkout-option-card {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 22px;
    padding: 20px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

.section-title,
.action-title,
.checkout-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.02em;
}

.action-title,
.checkout-title {
    font-size: 1rem;
}

/* SCREEN HELP */

.screen-help-button {
    width: 34px;
    height: 34px;
    border: 1px solid #cfe2ff;
    border-radius: 12px;
    background: #eef6ff;
    color: #0d6efd;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.92rem;
    flex-shrink: 0;
    transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

    .screen-help-button:hover {
        background: #0d6efd;
        color: #ffffff;
        transform: translateY(-1px);
    }

.screen-help-content {
    border: 1px solid #e8edf3;
    border-radius: 24px;
    box-shadow: 0 22px 50px rgba(15, 23, 42, 0.14);
    overflow: hidden;
}

.screen-help-header,
.screen-help-footer {
    border-color: #eef2f7;
    background: #f8fbff;
}

.screen-help-title {
    color: #111827;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.screen-help-description {
    color: #475569;
    font-weight: 600;
    margin-bottom: 14px;
}

.screen-help-list {
    color: #334155;
    margin: 0;
    padding-left: 1.15rem;
}

    .screen-help-list li {
        margin-bottom: 9px;
    }

        .screen-help-list li:last-child {
            margin-bottom: 0;
        }

/* INPUTS */

.input-group-modern .form-control,
.input-group-modern .input-group-text {
    border-color: #dbe4ef;
    min-height: 44px;
}

.input-group-modern .input-group-text {
    background: #f8fafc;
    color: #64748b;
}

.form-control,
.form-select {
    border-color: #dbe4ef;
}

    .form-control:focus,
    .form-select:focus {
        border-color: #86b7fe;
        box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.12);
    }

/* BUTTONS */

.rincon-navbar-logo {
    max-width: 130px;
}

.cart-floating-button {
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    z-index: 1050;
    background-color: #523500;
}

.cart-floating-icon {
    color: #ebd2a5;
}

.btn-modern,
.btn-confirm-sale {
    border-radius: 12px;
    font-weight: 700;
    min-height: 42px;
    padding-inline: 18px;
    box-shadow: 0 8px 18px rgba(13, 110, 253, 0.18);
}

.btn-confirm-sale {
    min-width: 260px;
    box-shadow: 0 8px 18px rgba(25, 135, 84, 0.2);
}

.btn-modern-sm {
    border-radius: 10px;
    font-weight: 700;
}

.btn-icon-search {
    min-width: 48px;
    border-radius: 0 12px 12px 0;
}

.btn-soft-secondary,
.btn-soft-danger,
.btn-soft-success,
.btn-soft-warning,
.btn-soft-box {
    border-radius: 12px;
    font-weight: 700;
    border: 1px solid transparent;
}

.btn-soft-secondary {
    background: #f1f5f9;
    color: #334155;
}

    .btn-soft-secondary:hover {
        background: #e2e8f0;
        color: #0f172a;
    }

.btn-soft-danger {
    background: #fff1f2;
    color: #dc3545;
    border-color: #ffe4e6;
}

    .btn-soft-danger:hover {
        background: #dc3545;
        color: #ffffff;
    }

.btn-soft-success {
    background: #ecfdf5;
    color: #198754;
    border-color: #bbf7d0;
}

    .btn-soft-success:hover {
        background: #198754;
        color: #ffffff;
    }

.btn-soft-warning {
    background: #fffbeb;
    color: #92400e;
    border-color: #fde68a;
}

    .btn-soft-warning:hover {
        background: #f59e0b;
        color: #ffffff;
        border-color: #f59e0b;
    }

.btn-check:checked + .btn-soft-secondary,
.btn-check:checked + .btn-soft-warning {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.14);
}

.btn-soft-box {
    background: #fff7ed;
    color: #8a4b12;
    border-color: #fed7aa;
}

    .btn-soft-box:hover {
        background: #f3c27b;
        color: #3b220d;
        border-color: #eab56f;
    }

/* TABLES */

.custom-table-wrapper {
    border: 1px solid #e8edf3;
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
}

.custom-table {
    color: #1f2937;
}

    .custom-table thead th {
        background: #f8fafc;
        color: #475569;
        font-size: 0.82rem;
        text-transform: uppercase;
        letter-spacing: 0.04em;
        border-bottom: 1px solid #e8edf3;
        padding: 14px 16px;
    }

    .custom-table tbody td {
        padding: 16px;
        border-color: #eef2f7;
        color: #1f2937;
        vertical-align: middle;
    }

    .custom-table tbody tr:hover {
        background: #fbfdff;
    }

/* DATATABLES FIX */

.dataTables_wrapper,
.dataTables_wrapper label,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    color: #1f2937 !important;
}

    .dataTables_wrapper select,
    .dataTables_wrapper input {
        color: #1f2937 !important;
        background-color: #ffffff !important;
        border: 1px solid #dbe4ef !important;
        border-radius: 10px !important;
        padding: 6px 10px !important;
    }

    .dataTables_wrapper .paginate_button {
        color: #1f2937 !important;
    }

table.dataTable tbody td {
    color: #1f2937 !important;
}

/* ADMIN FORMS */

.admin-form-grid {
    row-gap: 1rem;
}

.admin-switch {
    width: 3rem;
    height: 1.5rem;
    cursor: pointer;
}

    .admin-switch:checked {
        background-color: #198754;
        border-color: #198754;
    }

    .admin-switch:not(:checked) {
        background-color: #dc3545;
        border-color: #dc3545;
    }

.admin-switch-label {
    margin-left: 0.5rem;
}

.article-sale-mode-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    width: min(430px, 100%);
    padding: 4px;
    border: 1px solid #cfe2ff;
    border-radius: 999px;
    background: #ffffff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.article-sale-mode-option {
    min-height: 42px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #334155;
    font-size: 0.9rem;
    font-weight: 900;
    letter-spacing: 0;
    line-height: 1.1;
    padding: 9px 14px;
    transition: background-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.article-sale-mode-option:hover {
    background: rgba(255, 255, 255, 0.72);
}

.article-sale-mode-option.active {
    background: #eef6ff;
    color: #0d6efd;
    box-shadow: inset 0 0 0 1px #cfe2ff;
}

.article-sale-mode-option:focus-visible {
    outline: 3px solid rgba(13, 110, 253, 0.24);
    outline-offset: 2px;
}

.article-preview-img {
    max-width: 220px;
    max-height: 220px;
    object-fit: contain;
    border-radius: 14px;
    border: 1px solid #dbe4ef;
    padding: 8px;
    background-color: #ffffff;
}

.image-empty-state {
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    padding: 32px 18px;
    color: #64748b;
    background: #f8fafc;
}

.datatable-action-group {
    display: inline-flex;
    justify-content: center;
    gap: 8px;
}

/* DETAIL PANELS */

.detail-metric-card {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
    height: 100%;
}

.detail-metric-label {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.detail-metric-value {
    color: #111827;
    font-size: 1.15rem;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.detail-metric-value.success {
    color: #198754;
    font-size: 1.75rem;
}

.cash-priority-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.metric-breakdown {
    display: grid;
    gap: 4px;
    color: #64748b;
    font-size: 0.82rem;
    line-height: 1.35;
}

/* STATISTICS */

.stats-filter-bar {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 20px;
    padding: 18px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

.stats-filter-label {
    color: #475569;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.batch-hero-search {
    width: min(560px, 100%);
}

.batch-hero-search-row {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) auto;
    gap: 10px;
    align-items: center;
}

.stats-chart-card {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 22px;
    padding: 20px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
    height: 100%;
}

.stats-low-stock-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.stats-chart-box {
    position: relative;
    min-height: 290px;
}

.stats-chart-box.tall {
    min-height: 360px;
}

.stats-product-card {
    padding: 0;
    overflow: hidden;
}

    .stats-product-card > .d-flex {
        padding: 20px 20px 14px;
        border-bottom: 1px solid #eef2f7;
    }

.stats-product-icon {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0d6efd;
    color: #ffffff;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.stats-product-subtitle {
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 700;
}

.stats-product-control {
    width: auto;
    min-width: 140px;
    border-radius: 10px;
    font-weight: 700;
}

.stats-product-ranking {
    display: flex;
    flex-direction: column;
}

.stats-product-ranking.scrollable {
    max-height: 720px;
    overflow-y: auto;
}

.stats-product-row {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) minmax(160px, 2.2fr) minmax(90px, auto);
    align-items: center;
    gap: 14px;
    min-height: 48px;
    padding: 10px 20px;
    border-bottom: 1px solid #eef2f7;
}

.stats-product-header {
    min-height: 42px;
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: #fbfdff;
}

.stats-product-header span:last-child {
    grid-column: 3;
    text-align: right;
}

.stats-product-name {
    color: #1f2937;
    font-size: 0.9rem;
    font-weight: 800;
}

.stats-product-bar-track {
    height: 28px;
    border-radius: 5px;
    background: #eef6ff;
    overflow: hidden;
}

.stats-product-bar {
    height: 100%;
    border-radius: 5px;
    background: linear-gradient(90deg, #0d6efd 0%, #67b7ff 100%);
}

.stats-product-row:nth-child(n+5) .stats-product-bar {
    background: linear-gradient(90deg, #8cc7ff 0%, #dceeff 100%);
}

.stats-product-value {
    color: #334155;
    font-size: 0.9rem;
    font-weight: 900;
    text-align: right;
    white-space: nowrap;
}

.stats-segmented {
    display: inline-flex;
    border: 1px solid #dbe4ef;
    border-radius: 14px;
    overflow: hidden;
    background: #ffffff;
}

.stats-segmented input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.stats-segmented label {
    margin: 0;
    padding: 10px 18px;
    color: #334155;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.stats-segmented input:checked + label {
    color: #ffffff;
    background: #0d6efd;
}

.stats-low-stock-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 360px;
    overflow-y: auto;
    padding-right: 6px;
}

.stats-low-stock-card .stats-low-stock-list {
    flex: 1 1 auto;
    max-height: none;
    min-height: 0;
}

.stats-low-stock-card .empty-state {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.stats-low-stock-footer {
    margin-top: auto !important;
}

.stats-low-stock-item {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
    border-bottom: 1px solid #eef2f7;
    padding-bottom: 12px;
}

.stats-low-stock-item:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.stock-alert-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    padding: 7px 10px;
    font-size: 0.78rem;
    font-weight: 900;
    white-space: nowrap;
}

.stock-alert-badge.warning {
    background: #fff8e1;
    color: #8a6500;
    border: 1px solid #ffe69c;
}

.stock-alert-badge.danger {
    background: #fff1f2;
    color: #dc3545;
    border: 1px solid #fecdd3;
}

/* SELECT2 */

.select2-container--bootstrap-5 .select2-selection {
    border-color: #dbe4ef;
    border-radius: 12px;
    min-height: 38px;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
    color: #1f2937;
    font-weight: 600;
    line-height: 1.5;
}

.select2-container--bootstrap-5 .select2-dropdown {
    border-color: #dbe4ef;
    border-radius: 14px;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.12);
    overflow: hidden;
}

.select2-container--bootstrap-5 .select2-search__field {
    border-color: #dbe4ef !important;
    border-radius: 10px !important;
}

.select2-container--bootstrap-5 .select2-results__option {
    font-weight: 700;
    padding: 9px 12px;
}

.select2-container--bootstrap-5 .select2-results__option--highlighted {
    background-color: #0d6efd;
}

/* AUTOCOMPLETE SEARCHES */

.personal-account-search-box {
    position: relative;
}

.personal-account-results {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 1060;
    max-height: 230px;
    overflow-y: auto;
    border: 1px solid #dbe4ef;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.14);
    padding: 6px;
}

.personal-account-result {
    width: 100%;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #1f2937;
    display: flex;
    align-items: center;
    padding: 10px 12px;
    text-align: left;
    font-size: 0.9rem;
    font-weight: 750;
    transition: background-color 0.16s ease, color 0.16s ease;
}

.personal-account-result:hover,
.personal-account-result:focus {
    background: #eef6ff;
    color: #0d6efd;
    outline: none;
}

.personal-account-result-message {
    color: #64748b;
    padding: 10px 12px;
    font-weight: 700;
}

/* SALES */

.sales-hero-filters {
    display: grid;
    grid-template-columns: minmax(190px, 1fr) minmax(160px, 0.85fr) auto;
    align-items: end;
    gap: 12px;
    width: min(620px, 100%);
}

.sales-filter-field label {
    color: #475569;
    display: block;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.sales-filter-field .form-control,
.sales-filter-field .form-select {
    min-height: 44px;
    border-radius: 12px;
}

/* CASH REGISTER */

.cash-inline-form,
.cash-close-form {
    display: grid;
    gap: 10px;
}

.cash-inline-form {
    grid-template-columns: minmax(180px, 240px) auto;
}

.cash-close-form {
    grid-template-columns: minmax(170px, 220px) minmax(220px, 1fr) auto;
    width: min(720px, 100%);
}

.cash-inline-form .form-control,
.cash-close-form .form-control,
.cash-inline-form .input-group-text,
.cash-close-form .input-group-text {
    min-height: 44px;
    border-radius: 12px;
}

.personal-account-settle-form {
    display: grid;
    grid-template-columns: 1fr minmax(150px, 200px) minmax(170px, 220px) minmax(220px, 1fr) auto;
    align-items: end;
    gap: 12px;
}

/* BADGES */

.role-badge,
.status-badge,
.stock-badge,
.expiration-badge,
.payment-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.role-admin {
    background: #eef6ff;
    color: #0d6efd;
    border: 1px solid #cfe2ff;
}

.role-employee {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #e5e7eb;
}

.role-empty {
    background: #f8fafc;
    color: #64748b;
    border: 1px solid #e2e8f0;
}

.status-active,
.stock-ok,
.expiration-ok {
    background: #ecfdf5;
    color: #198754;
    border: 1px solid #bbf7d0;
}

.status-inactive,
.status-blocked,
.expiration-danger {
    background: #fff1f2;
    color: #dc3545;
    border: 1px solid #fecdd3;
}

.stock-low,
.status-warning,
.expiration-warning {
    background: #fff8e1;
    color: #8a6500;
    border: 1px solid #ffe69c;
}

.status-neutral {
    background: #f8fafc;
    color: #64748b;
    border: 1px solid #e2e8f0;
}

.expiration-empty {
    background: #f8fafc;
    color: #64748b;
    border: 1px solid #e2e8f0;
}

.payment-cash {
    background: #ecfdf5;
    color: #198754;
    border: 1px solid #bbf7d0;
}

.payment-transfer {
    background: #eef6ff;
    color: #0d6efd;
    border: 1px solid #cfe2ff;
}

/* EMPTY STATES */

.empty-state {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 26px;
    padding: 42px 24px;
    text-align: center;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

    .empty-state.compact {
        padding: 34px 20px;
        box-shadow: none;
        background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    }

.empty-illustration {
    width: 96px;
    height: 96px;
    border-radius: 30px;
    background: #eef6ff;
    color: #0d6efd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.8rem;
    margin: 0 auto 20px;
    position: relative;
}

    .empty-illustration::after {
        content: "";
        position: absolute;
        width: 112px;
        height: 112px;
        border-radius: 34px;
        border: 1px dashed #bfd7ff;
    }

.empty-state h2,
.empty-state h3 {
    font-weight: 900;
    color: #111827;
    letter-spacing: -0.03em;
}

.empty-state p {
    color: #6b7280;
    max-width: 520px;
    margin: 0 auto 22px;
}

/* ALERTS */

.custom-alert-danger,
.custom-alert-warning,
.custom-alert-info {
    border: 0;
    border-radius: 18px;
    padding: 14px 16px;
    font-weight: 600;
}

.custom-alert-danger {
    background: #fff1f2;
    color: #b02a37;
}

.custom-alert-warning {
    background: #fff8e1;
    color: #8a6500;
}

.custom-alert-info {
    background: #eef6ff;
    color: #0d6efd;
}

.validation-summary-valid.custom-alert-danger {
    display: none;
}

/* AUTH */

.auth-page {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px 0;
    color: #1f2937;
}

.auth-shell {
    width: min(1040px, 100%);
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 24px;
    align-items: stretch;
}

.auth-visual,
.auth-card,
.auth-status-card {
    background: linear-gradient(135deg, #f8fafc 0%, #eef6ff 100%);
    border: 1px solid #e5edf7;
    border-radius: 28px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
    position: relative;
    overflow: hidden;
}

.auth-visual {
    padding: 32px;
    min-height: 470px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

    .auth-visual::before {
        content: "";
        position: absolute;
        inset: 18px;
        border: 1px solid rgba(13, 110, 253, 0.16);
        border-radius: 22px;
        background-image: linear-gradient(rgba(13, 110, 253, 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(13, 110, 253, 0.08) 1px, transparent 1px);
        background-size: 28px 28px;
        mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.85), transparent);
        pointer-events: none;
    }

.auth-visual-content,
.auth-visual-footer {
    position: relative;
    z-index: 1;
}

.auth-visual-image {
    position: relative;
    z-index: 1;
    display: block;
    width: min(320px, 72%);
    max-height: 320px;
    object-fit: contain;
    margin: 22px auto;
    filter: drop-shadow(0 18px 28px rgba(15, 23, 42, 0.12));
    opacity: 0.94;
}

.auth-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #0d6efd;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-title {
    color: #111827;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.auth-subtitle,
.auth-copy {
    color: #64748b;
}

.auth-card {
    padding: 28px;
    background: #ffffff;
    animation: authPanelIn 0.48s ease-out both;
}

.auth-card-header {
    margin-bottom: 22px;
}

.auth-icon,
.auth-status-icon {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eef6ff;
    color: #0d6efd;
    font-size: 1.55rem;
    box-shadow: inset 0 0 0 1px #cfe2ff;
}

.auth-icon {
    animation: authPulse 2.8s ease-in-out infinite;
}

.auth-field .form-control {
    min-height: 52px;
    border-radius: 14px;
}

.auth-field label {
    color: #64748b;
}

.auth-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.auth-link {
    color: #0d6efd;
    font-weight: 700;
    text-decoration: none;
}

    .auth-link:hover {
        text-decoration: underline;
    }

.auth-metric {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid #dbeafe;
    color: #334155;
    font-weight: 800;
    padding: 8px 12px;
}

.auth-status-page {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px 0;
}

.auth-status-card {
    width: min(640px, 100%);
    padding: 36px;
    text-align: center;
    background: #ffffff;
    animation: authPanelIn 0.48s ease-out both;
}

.auth-status-icon {
    width: 86px;
    height: 86px;
    border-radius: 28px;
    font-size: 2.2rem;
    margin: 0 auto 22px;
}

.auth-status-icon.danger {
    background: #fff1f2;
    color: #dc3545;
    box-shadow: inset 0 0 0 1px #fecdd3;
    animation: authDeniedPulse 1.7s ease-in-out infinite;
}

.auth-status-icon.warning {
    background: #fff8e1;
    color: #8a6500;
    box-shadow: inset 0 0 0 1px #ffe69c;
    animation: authLockShake 2.6s ease-in-out infinite;
}

.auth-status-title {
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #111827;
}

.auth-status-text {
    max-width: 460px;
    margin: 0 auto 24px;
    color: #64748b;
}

@keyframes authPanelIn {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes authPulse {
    0%,
    100% {
        box-shadow: inset 0 0 0 1px #cfe2ff, 0 0 0 0 rgba(13, 110, 253, 0.22);
    }

    50% {
        box-shadow: inset 0 0 0 1px #cfe2ff, 0 0 0 12px rgba(13, 110, 253, 0);
    }
}

@keyframes authDeniedPulse {
    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

@keyframes authLockShake {
    0%,
    82%,
    100% {
        transform: translateX(0);
    }

    86% {
        transform: translateX(-4px);
    }

    90% {
        transform: translateX(4px);
    }

    94% {
        transform: translateX(-2px);
    }
}

/* SWEETALERT CONFIRMATIONS */

.rincon-swal-popup {
    border-radius: 22px;
    padding: 26px;
    border: 1px solid #e8edf3;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

.rincon-swal-title {
    color: #111827;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.rincon-swal-confirm,
.rincon-swal-cancel {
    border-radius: 12px !important;
    font-weight: 800 !important;
    min-width: 120px;
    box-shadow: none !important;
}

/* CART */

.quantity-short {
    max-width: 130px;
}

.quantity-editor {
    width: 158px;
}

.quantity-result-input {
    width: 82px;
    text-align: center;
}

.btn-quantity {
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 10px;
    border: 1px solid #dbe4ef;
    background: #ffffff;
    color: #475569;
}

    .btn-quantity:hover {
        background: #f1f5f9;
        color: #0f172a;
    }

.btn-remove {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 12px;
    border: 0;
    background: #fff1f2;
    color: #dc3545;
}

    .btn-remove:hover {
        background: #dc3545;
        color: #ffffff;
    }

.stock-text,
.line-total {
    font-weight: 800;
}

.cart-count-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border-radius: 999px;
    background: #eef6ff;
    color: #0d6efd;
    font-size: 0.88rem;
    font-weight: 700;
    padding: 8px 12px;
}

.change-result {
    font-weight: 800;
    color: #64748b;
}

.mini-warning {
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #9a3412;
    border-radius: 14px;
    padding: 10px 12px;
    font-size: 0.9rem;
}

.main-empty {
    min-height: 320px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 20% 20%, rgba(13, 110, 253, 0.08), transparent 28%), radial-gradient(circle at 80% 30%, rgba(25, 135, 84, 0.08), transparent 26%), #ffffff;
}

.cart-empty {
    background: #ecfdf5;
    color: #198754;
}

    .cart-empty::after {
        border-color: #b7ebcd;
    }

.empty-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

/* TOTAL */

.total-panel-compact {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    background: #f8fafc;
    border: 1px solid #e8edf3;
    border-radius: 14px;
    padding: 12px 18px;
    min-width: auto;
    text-align: right;
}

.total-label {
    color: #64748b;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.total-amount-compact {
    font-size: 1.55rem;
    font-weight: 900;
    color: #198754;
    letter-spacing: -0.03em;
    line-height: 1;
}

/* SUCCESS MODAL */

.sale-success-modal {
    overflow: hidden;
}

.success-check-wrapper {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background-color: #198754;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: successPop 0.45s ease-out;
}

.success-check-icon {
    color: #fff;
    font-size: 3rem;
    animation: checkBounce 0.65s ease-out;
}

@keyframes successPop {
    0% {
        transform: scale(0.4);
        opacity: 0;
    }

    70% {
        transform: scale(1.12);
        opacity: 1;
    }

    100% {
        transform: scale(1);
    }
}

@keyframes checkBounce {
    0% {
        transform: scale(0);
        opacity: 0;
    }

    50% {
        transform: scale(1.25);
        opacity: 1;
    }

    100% {
        transform: scale(1);
    }
}

/* PRODUCT IMAGES */

.product-img-sm,
.cart-product-img,
.cart-product-placeholder {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    object-fit: cover;
    flex-shrink: 0;
}

.product-card-img {
    object-fit: cover;
}

.cart-product-placeholder,
.product-img-placeholder {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
}

/* RESPONSIVE */

@media (max-width: 768px) {
    .sales-hero-filters {
        grid-template-columns: 1fr;
    }

    .cash-inline-form,
    .cash-close-form,
    .personal-account-settle-form {
        grid-template-columns: 1fr;
        width: 100%;
    }

    .auth-page,
    .auth-status-page {
        min-height: auto;
        padding: 20px 0;
    }

    .auth-shell {
        grid-template-columns: 1fr;
    }

    .auth-visual {
        min-height: 260px;
        padding: 22px;
    }

    .auth-visual-image {
        width: min(240px, 68%);
        max-height: 240px;
        margin: 16px auto;
    }

    .auth-card,
    .auth-status-card {
        border-radius: 20px;
        padding: 22px;
    }

    .rincon-hero,
    .admin-hero,
    .cart-hero,
    .action-card,
    .content-card,
    .form-card,
    .checkout-card,
    .checkout-option-card {
        border-radius: 18px;
        padding: 16px;
    }

    .total-panel-compact {
        width: 100%;
        justify-content: space-between;
    }

    .input-group-modern {
        flex-wrap: nowrap;
    }

    .quantity-short {
        max-width: 110px;
    }

    .article-sale-mode-toggle {
        width: 100%;
    }

    .article-sale-mode-option {
        font-size: 0.76rem;
        min-height: 48px;
        padding-inline: 8px;
    }

    .total-panel {
        width: 100%;
        text-align: left;
    }

    .btn-confirm-sale {
        width: 100%;
    }
}
