.box {
    /* height: 110px; */
    flex: 1 0 0;
    display: block;
    flex-basis: 50%;
    padding: 15px;
    align-items: center;
    transition: all 0.3s ease;
    text-decoration: none;
    color: black;
    border-radius: 10px;
}
@media (min-width: 708px) {
    .box {
        flex-basis: 20%;
    }
}
.box:hover{
    transform: scale(0.93);
}

.skeleton-line,
.skeleton-circle {
    animation: skeletonPulse 1.2s ease-in-out infinite;
    background: linear-gradient(90deg, #eef1f5 0%, #f8fafc 45%, #eef1f5 100%);
    background-size: 220% 100%;
    display: block;
}

.skeleton-line {
    border-radius: 999px;
    height: 12px;
}

.skeleton-circle {
    border-radius: 50%;
    flex: 0 0 34px;
    height: 34px;
    width: 34px;
}
@keyframes skeletonPulse {
    0% {
        background-position: 100% 0;
    }

    100% {
        background-position: -100% 0;
    }
}

.cdx {
    flex: 1 0 0;
    justify-content: left;
    align-items: center;
    border-radius: 10.431px;
}
.cdx-success {
    border: 1.5px solid #16DD65 !important;
}
.cdx-danger {
    border: 1.5px solid #F73434 !important;
}
.cdx-warning {
    border: 1.5px solid #F7AE34 !important;
}
.cdx-content {
    display: flex; 
    flex-direction: column; 
    /* border: 1.5px solid #16DD65 !important;
    border-width: 5px; */
    align-items: center; 
    justify-content: center
}


.spinner-border {
    display: inline-block;
    width: 0.8rem;
    height: 0.8rem;
    margin-bottom: -3px;
    border: 0.15em solid rgb(119 135 224);
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}
  
@keyframes spinner-border {
    to {
        transform: rotate(360deg);
    }
}


.picture-upload{
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 225px;
    justify-content: center;
    min-height:150px;
    background-image: url('');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;                             
}

.row_ {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    align-items: flex-start;
    gap: 20px;
  }
  
  .row__ {
      display: flex;
      flex-wrap: wrap;
      /* width: 60%; */
      gap: 20px;
  }
  
  .di1 .di2 .di3 {
      display: flex;
  }
  
  @media (max-width: 708px) {
      .di3{
          display: none;
      }
  }
  @media (max-width: 450px) {
      .di2{
          display: none;
      }
  }
  @media (max-width: 400px) {
      .di1{
          display: none;
      }
  }

#camera-container {
    position: relative;
    /* width: 100%; */
    height: 300px;
}

#camera {
    background-color: black;
    background-position: center;
    height: 300px;
    /* transform: scaleX(-1); */
    width: 100%;
    object-fit: cover;
    border-radius: 15px;
}

#camera video {
    position: absolute;
    border: 3px solid #062433 !important;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scaleX(-1);
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures it fills the container */
    border-radius: 15px; /* Ensures video itself has rounded corners */
}

.scanning-line {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: rgba(0, 255, 102, 0.7);
    animation: scan 1.5s linear infinite;
    filter: blur(4px); /* Apply blur effect */
    pointer-events: none; /* Ensures the line doesn't block other interactions */
}

@keyframes scan {
    0% {
        top: 0%;
        filter: blur(4px); /* Start with blur */
    }
    50% {
        top: 50%;
        filter: blur(4px); /* Maintain blur effect */
    }
    100% {
        top: 100%;
        filter: blur(4px); /* Maintain blur effect */
    }
}



/* Dashboard Chart Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out forwards;
    opacity: 0;
}

/* Chart Loader Styles */
.chart-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    gap: 15px;
}

.chart-loader .spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.3rem;
}

.chart-loader-text {
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
}

/* Revenue Expense Chart Styles */
#revenueExpenseChart {
    min-height: 200px;
    max-height: 250px;
    position: relative;
    transition: opacity 0.5s ease-in;
}

/* Weekly Chart Styles */
#transaction_weekly_chart {
    min-height: 280px;
    max-height: 320px;
    position: relative;
    transition: opacity 0.5s ease-in;
}

/* Payment Metrics Card Enhancements */
.payment-metrics {
    transition: opacity 0.5s ease-in;
}

.metric-cell {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.metric-cell::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s ease;
}

.metric-cell:hover::before {
    left: 100%;
}

.metric-cell:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Mini bars animation */
.mini-bars span {
    display: inline-block;
    transition: all 0.3s ease;
}

.metric-cell:hover .mini-bars span {
    transform: scaleY(1.1);
}

/* Card styles for charts */
.card .card-body {
    position: relative;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #revenueExpenseChart {
        min-height: 180px;
        max-height: 220px;
    }
    
    #transaction_weekly_chart {
        min-height: 250px;
        max-height: 280px;
    }
}

/* Skeleton loader for charts */
@keyframes skeleton-loading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton-loader {
    background: linear-gradient(90deg, #f0f0f0 0px, #f8f8f8 40px, #f0f0f0 80px);
    background-size: 200px 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 8px;
}
