#iconos-widgets{
    display: flex;
    /* gap:8px; */
    margin-top: 44px;
    margin-right: 10px;
    width: calc(100% - 10px);
}

.widget {
    display: flex;
    flex: 1 1 100px;
    padding:3px;
    /* border:solid 1px black; */
    border-radius: 4px;
    height: auto;
    
    /* align-items: stretch; */
    align-items: flex-start;
    /* justify-content: space-evenly; */
    flex-wrap: wrap;    

}

.titulo-widget {
    flex-basis: 100%;
    display:flex;
}
.cuerpo-widget {
    flex-basis: 100%;
    display:flex;
    flex-wrap: wrap;
    gap: 8px;
    /* flex: 4; */
    /* margin: 2px 7px 7px 6px; */
}
.column-1 {
    flex-basis: 100%;
    width:100%;
}
.grow-2{
    flex:2;
}

.column-2 .cuerpo-widget{
    flex: 1;
    display: flex;
    justify-content: center;
    align-content: center;
}

.texto-widget-small .imagen-widget{
    display: flex;
    flex-basis: 100%;
    justify-items: center;
    justify-content: center;
    align-items: center;
    flex-basis: 30%;
}
.texto-widget-small{
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    text-align: right;
    font-weight: bold;
    text-transform: uppercase;
    padding-bottom: 9px;
}
.icono{
    width: 50px
}
/* .soy-widget{ */
    /* background-color: red; */
    /* gap:10px; */
   /* margin: 2px 7px 7px 6px; */

/* } */
.texto-widget-small .titulo-widget{
    font-size: 15px;
    margin-top: 10px;
    /* flex-basis: 100%; */
    justify-content: center;

}
.texto-widget-small .cuerpo-widget{
    font-size: 40px;
    /* flex-basis: 70%;  */
    display: flex;
    justify-content: center;
    /* flex: 4; */
    
}
.column-2 .cuerpo-widget{
    flex: 1;
    display: flex;
    justify-content: center;
    align-content: center;
}
.fila-1 .cuerpo-widget{
    flex: 4;
}
/* .fila-2 .cuerpo-widget{
    flex: 1;
} */
.fila-3 .cuerpo-widget{
    flex: 4;
}
.column-lateral .cuerpo-widget {
    display: flex;
    flex:1;
    margin: 15px;
    flex-direction: column;
}
.btn-lateral{
    width: 100%;
}
.num{
    width: 100%;
    font-size: 45px !important;
    /* margin-top: -65px;
    padding-top: 55px; */
    color: white;   
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.6), 0 0 5px rgba(255, 255, 255, 0.2);
    text-align: center;
    transition: text-shadow 0.3s ease, color 0.3s ease;
}
.num:hover {
    transform: scale(1.2);
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.8), 0 0 8px rgba(255, 255, 255, 0.4);
    color: #f8f9fa;
}
.cont-widget-small{
    line-height: 100px;
    display: inline-block;
    font-size: 25px;
}
/* .cont-totales{
    width: 100%;
    margin: 10px;
} */

/* widget de resumen */
@media (max-width: 1768px) {
    .cont-totales {
        min-height: auto;
        padding: 15px;
        margin: 5px;
    }
}

.cont-totales {
    width: 100%;
    margin: 10px;
    background: #fff;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    min-height: 318.594px;
}

.cont-totales .header {
    text-align: center;
    margin-bottom: 20px;
}

.cont-totales .imagen-principal {
    width: 64px;
    height: 64px;
    margin-bottom: 8px;
}

.cont-totales .header h3 {
    margin: 0;
    font-size: 18px;
    color: #444;
}

.cont-totales .grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
}
.grid-clientes{
    display: grid;
    gap: 15px;
}
.cont-totales .item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 12px;
    text-align: center;
    transition: background 0.2s ease;
}

.cont-totales .item:hover {
    background: #eef2f6;
}

.cont-totales .titulo {
    display: block;
    font-size: 14px;
    color: #666;
}

.cont-totales .dato {
    display: block;
    font-size: 20px;
    font-weight: bold;
    color: #222;
}

.cont-totales .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    /* siempre 2 columnas */
    gap: 15px;
}


/* --------- botones ---------- */


/* .cont-totales sl-button::part(base) {
    width: 100%;
    height: 80px;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    
} */
.crear-pedido-btn {
  --sl-color-primary-500: #6B8E23; 
  --sl-color-primary-600: #8bb32c;
    font-size: 15px;

}
.crear-gasto-btn {
  --sl-color-primary-500: #9ACD32; 
  --sl-color-primary-600: #8bb32c;
}

.crear-pedido-btn::part(base),
.crear-gasto-btn::part(base) {
    display: flex;
    align-items: center; 
    justify-content: center; 
}
/* ----------------- widget clientes */
.acciones-clientes {
  width: 100%;
  display: flex;
  flex-direction: column;   /* uno debajo del otro */
  align-items: flex-start;    /* pegados a la derecha */
  gap: 3px;                /* separación entre botones */
}

.resumen-clientes {
  display: flex;
  flex-direction: column;
  align-items: center;      /* centra imagen + título */
  /* margin-top: 20px; */
}

.imagen-cliente {
  width: 64px;
  height: 64px;
  margin-bottom: 8px;
}

.titulo-resumen {
  margin: 0;
  font-size: 18px;
  color: #444;
  margin-bottom: 10px;
  margin-top: 10px;
}
/* ------------- */
.resumen-pedidos {
  display: flex;
  flex-direction: column;
  align-items: center;      /* centra imagen + título */
  margin-top: -70px;
}
.resumen-facturas {
  display: flex;
  flex-direction: column;
  align-items: center;      
  margin-top: -34px;
}
/*
----------------------------
        NUEVOS WIDGETS 
----------------------------
*/

   .card-container {
        width: 100%;
        font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
        border-radius: 24px;
        overflow: hidden;
        background: white;
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }
    .card-container-avisos {
        width: 100%;
        font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
        border-radius: 24px;
        overflow: hidden;
    }
    .card-header {
        background: var(--purple-gradient);
        color: white;
        padding: 15px 20px 30px;
        font-weight: bold;
        font-size: 1.1rem;
        letter-spacing: 0.5px;
    }
    #desplagable-avisos wa-details::part(base){
        background: var(--purple-gradient);
        color: white;
        border-radius: 24px;
    }
    #desplagable-avisos wa-details::part(icon) {
        color: white;
        font-size: 22px;
    }

    #desplagable-avisos wa-details::part(content) {
        padding-inline: 0;
        padding-block-end: 0;
    }
    .card-content {
        padding: 20px;
        background: white;
        border-radius: 20px;
        margin-top: -20px; /* clave para que se superponga */
        position: relative;
        z-index: 1;
    }

    .label {
        margin: 0;
        color: var(--text-dark);
        font-size: 1.1rem;
        font-weight: 500;
        text-align: right; /*New*/
    }

    .stats-row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin: 15px 0 25px 15px;
    }

    .main-number {
        font-size: 3.5rem;
        font-weight: 700;
        color: #2d3436;
    }

    .trend-badge {
        background-color: var(--success-green);
        color: var(--success-text);
        padding: 6px 12px;
        border-radius: 8px;
        display: flex;
        align-items: center;
        gap: 5px;
        font-weight: bold;
        font-size: 1rem;
    }

    .actions {
        padding-top: 10px;
        display: flex;
        gap: 10px;
    }


    .btn-outline {
        background: white;
        color: var(--purple-primary);
        border: 1px solid #e0e0e0;
        border-radius: 5px;

    }

    wa-button::part(base) {
        border: none;
    }
 
    wa-button.btn-purpura::part(base) {
        background-color: #6c2ba4 !important;
        border-color: #5a248a !important; 
        color: white !important;
        padding: 0 10px;
        transition: all 0.2s ease;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    wa-button.btn-purpura:hover::part(base) {
        background-color: #7e32bf !important;
        border-color: #6c2ba4 !important;
        
    }
    wa-button.w-120::part(base) {
        width: 120px;
    }
     .stat-item {
        display: flex;
        flex-direction: column;
        align-items: flex-start; 
        background: #b2b2b214;
        border-radius: 5px;
        gap: 2px;
        padding-left: 10px;
    }

    .btn-outline::part(base) {
        height: 30px;
    }

    .stats-column {
        display: flex;
        flex-direction: column;
        gap: 6px;
        margin-bottom: 20px;
    }

    .stat-item .label {
        margin: 0;
        font-size: 0.95rem;
        color: #555;
    }

    .amount {
        font-size: 1.25rem;
        font-weight: 700;
        color: #2d3436;
    }
    .widget-factura-column {
        display: flex;
        flex-direction: row; 
        align-items: stretch;
        gap: 20px; 
        margin-bottom: 20px;
    }

    .stats-group {
        display: flex;
        flex-direction: column; 
        gap: 10px;
        flex: 1; 
    }
    /* .desplegable-albaran wa-icon{
        margin-right: 2px;
        padding-right: 10px;
    }
        
    .desplegable-albaran{
        display: flex; 
        flex-direction: column; 
        gap: 4px; 
        align-items: stretch;
    } */
    wa-callout::part(message){
        font-size: 0.95rem;
    }
    