/*STYLE PARA LA PANTALLA DE CARGAR*/
#cover {
    width: 100%;
    height: 100%;
    position: fixed;
    background-color: #131313;
    opacity: 0.9;
    display: none;
    z-index: 9999;
    top: 0;
}

div>div#cover {
    position: fixed;
}

#loading {
    font-weight: 700;
    width: 250px;
    height: 75px;
    background-color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    margin-top: -30px;
    margin-left: -120px;
    border: 2px solid #2563EB;
    border-radius: 10px;
    opacity: 1;
    padding: 0px 10px;
    box-shadow: 2px 2px 0.25px #12344D;
}

div>div#loading {
    position: fixed;
}

#loading_content {
    width: 260px;
}

#loading img {
    float: left;
    max-width: 65px;
}

#loading_content h3 {
    margin: 0;
    font-size: 12px;
    font-weight: bold;
}





#cover_clonar_producto {
    width: 100%;
    height: 100%;
    position: fixed;
    background-color: #131313;
    opacity: 0.9;
    display: none;
    z-index: 9999;
    top: 0;
}

div>div#cover_clonar_producto {
    position: fixed;
}

#loading_clonar_producto {
    font-weight: 700;
    width: 250px;
    height: 75px;
    background-color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    margin-top: -30px;
    margin-left: -120px;
    border: 2px solid #2563EB;
    border-radius: 10px;
    opacity: 1;
    padding: 0px 10px;
    box-shadow: 2px 2px 0.25px #12344D;
}

div>div#loading_clonar_producto {
    position: fixed;
}

#loading_content_clonar_producto {
    width: 260px;
}

#loading_clonar_producto img {
    float: left;
    max-width: 65px;
}

#loading_content_clonar_producto h3 {
    margin: 0;
    font-size: 12px;
    font-weight: bold;
}


#id_td_hr hr {
    border: none;
    border-left: 2px solid #2563EB;
    height: 40px;
    width: 1px;
}


.css_hold_cambiar:hover {
    cursor: pointer;
    text-decoration: underline;
}

:root {
    --brand: #5596f7;
    --brand-light: #b7ccf8;
    --brand-dark: #1c5194;
    --accent: #534AB7;
    --accent-light: #EEEDFE;
    --text-main: #2C2C2A;
    --text-muted: #888780;
    --surface: #F8F9FA;
    --card-border: rgba(0, 0, 0, 0.08);
}

.search-wrap {
    position: relative;
    max-width: 560px;
    margin: 1.5rem auto 0;
}

.search-wrap .bi-search {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1.1rem;
    pointer-events: none;
    z-index: 2;
}


#id_txt_buscar_empresa {
    width: 100%;
    padding: .75rem 1rem .75rem 2.75rem;
    border-radius: 10px;
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, .18);
    outline: none;
    transition: box-shadow .2s;
}

#id_txt_buscar_empresa:focus {
    box-shadow: 0 4px 24px rgba(0, 0, 0, .28), 0 0 0 3px #BDCFEC;
}

/* ── jQuery UI Autocomplete ── */
.ui-autocomplete {
    border: 0.5px solid #BDCFEC;
    border-radius: 10px;
    box-shadow: #BDCFEC;
    overflow: hidden;
    padding: 4px 0;
    max-height: 280px;
    overflow-y: auto;
}

.ui-menu-item-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px;
    font-size: .9rem;
    color: var(--text-main);
    cursor: pointer;
    transition: background .15s;
}

.ui-menu-item-wrapper:hover,
.ui-state-active {
    background: var(--brand-light) !important;
    color: var(--brand-dark) !important;
    border: none !important;
}

.ui-menu-item-wrapper .badge-cat {
    margin-left: auto;
    font-size: .7rem;
    padding: 2px 8px;
    border-radius: 20px;
    background: var(--accent-light);
    color: var(--accent);
    font-weight: 500;
}


/* ── Cards de resultados ── */
.result-card {
    background: #fff;
    border: 0.5px solid var(--card-border);
    border-radius: 14px;
    transition: box-shadow .2s, transform .2s;
    overflow: hidden;
    height: 100%;
}

.result-card:hover {
    box-shadow: 0 6px 24px rgba(0, 0, 0, .1);
    transform: translateY(-2px);
}

.card-img-top {
    height: 160px;
    object-fit: cover;
    background: var(--brand-light);
}

.card-img-placeholder {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

.card-body {
    padding: 1rem;
}

.card-category {
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .5px;
    text-transform: uppercase;
    color: var(--brand-dark);
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    margin: .3rem 0 .5rem;
    line-height: 1.3;
}

.card-desc {
    font-size: .82rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.card-footer-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .65rem 1rem;
    border-top: 0.5px solid var(--card-border);
    background: #fafafa;
}

.card-price {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--brand-dark);
}

.card-rating i {
    color: #EF9F27;
    font-size: .8rem;
}

.card-rating span {
    font-size: .78rem;
    color: var(--text-muted);
    margin-left: 3px;
}


/* ── Skeleton loader ── */
.skeleton {
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    border: 0.5px solid var(--card-border);
}

.skeleton-line {
    background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%);
    background-size: 200% 100%;
    animation: shimmer 1.2s infinite;
    border-radius: 6px;
}

@keyframes shimmer {
    to {
        background-position: -200% 0;
    }
}

/* ── Estado vacío ── */
.empty-state {
    padding: 4rem 1rem;
    text-align: center;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 3.5rem;
    color: #D3D1C7;
    display: block;
    margin-bottom: 1rem;
}

/* ── Paginación ── */
.page-link {
    color: var(--brand);
}

.page-item.active .page-link {
    background: var(--brand);
    border-color: var(--brand);
}

.cursor-pointer {
    cursor: pointer !important;
}

.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.75);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-spinner {
    width: 36px;
    height: 36px;
    border: 4px solid #e0e0e0;
    border-top-color: #0d6efd;
    /* color primario de Bootstrap */
    border-radius: 50%;
    animation: girar-spinner 0.7s linear infinite;
}

.loading-text {
    margin-top: 10px;
    font-size: 0.9rem;
    color: #555;
}

@keyframes girar-spinner {
    to {
        transform: rotate(360deg);
    }
}
/* icono de Stratox DTE en la pantalla de carga (Interfaces::header) */
#loading img.stx-cargando,
#loading_clonar_producto img.stx-cargando {
    max-width: 42px;
    margin: 4px 6px;
    animation: stx-latido 1.2s ease-in-out infinite;
}

@keyframes stx-latido {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(.88); opacity: .7; }
}
