.limit-cards-wrapper {
  min-width: 100%;
  width: 100%;
  /* flex: 1; */
  display: flex;
  justify-content: center;
  padding: 32px;
  overflow: hidden;
  isolation: isolate;
  position: relative;
  z-index: 1;
  max-height: 300px;
    @media (max-width: 768px) {
        padding: 0 0 18px 0;
    }
}

.limit-line--expanded {
    display: flex;
    color: var(--neutral-white);
    margin-bottom: 8px;
    margin-top: 32px;
}

.limit-line--collapsed {
    display: none !important;
}

.limit-overdue_debt--expanded {
    display: flex;
    flex-direction: column;
    text-align: right;
}

.limit-overdue_debt--collapsed {
    display: none;
}

.limit-cards--collapsed .progress-linear {
    height: 26px;
    overflow: hidden;
    margin-top: 8px;
}

.limit-cards--collapsed .limit-subtitle { display: none; }
.limit-cards--collapsed .limit-increase-link { display: none; }

.limit-cards--collapsed .limit-line--expanded { display: none; }
.limit-cards--collapsed .limit-line--collapsed {
    margin-top: 1px;
    display: flex !important;
    height: 26px;
    position: absolute;
    inset: 0;
    /* align-items: center; */
    top: 2px;
    left: 16px;
    color: var(--neutral-white);
    white-space: nowrap;
    z-index: 1;
    font-family: Commissioner;
    font-weight: 300;
    font-size: 16px;
    line-height: 110%;
}

.limit-cards--collapsed .limit-overdue_debt--expanded { display: none; }
.limit-cards--collapsed .limit-overdue_debt--collapsed {
    display: flex;
    flex-direction: row;
}

.limit-cards--collapsed .progress-linear {
    height: 26px;
    overflow: hidden;
}

.limit-toggle-btn {
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
  width: 29px;
  height: 29px;
  padding: 0;
  box-shadow: none;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 17px;
  border-width: 0.5px;
  backdrop-filter: blur(10px);
  border: 0.5px solid;
  border-image-source: linear-gradient(45deg, rgba(107, 158, 255, 0.7) 0%, rgba(107, 158, 255, 0) 50%, rgba(107, 158, 255, 0.7) 100%);
  background: linear-gradient(90deg, rgba(72, 110, 181, 0.3) 0%, rgba(107, 158, 255, 0.3) 100%);

}

.limit-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.limit-cards-container {
    min-width: 100%;
    width: 100%;
    flex: 1;
    padding: 0;
    border-radius: 64px;
    background: url('../image/bg.png') top / cover no-repeat;
    background-size: 100% 120%;
    overflow: visible;
    position: relative;
    z-index: 1;
        @media (max-width: 768px) {
            border-radius: 0;
        }
}

.limit-cards-subcontainer {
    gap: 32px !important;
    min-width: 100%;
    width: 100%;
    padding: 1rem;
    border-radius: 64px;
    display: grid;
    grid-template-columns: repeat(3, minmax(359px, 1fr));
    column-gap: 24px;
    scroll-padding-inline-end: 1rem;
    overflow: auto hidden;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    /* transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1); */
    transition: all 0.3s ease;
        @media (max-width: 768px) {
            border-radius: 0;
        }
}


.limit-cards-subcontainer {
    height: 232px; 
}

.limit-cards-subcontainer::-webkit-scrollbar {
  display: none;
}

.limit-card {
  min-width: 377px;
  text-align: left;
  display: grid;
  grid-template: 'content' 1fr 'progress' auto / 1fr;
  gap: 0 16px;
  height: 200px;
  box-sizing: border-box;
  position: relative;
  z-index: 1;
  border: 1px solid;
  border-image-source: linear-gradient(
    146.08deg,
    rgba(255, 255, 255, 0) 9.62%,
    rgba(255, 255, 255, 0.4) 49.8%,
    rgba(255, 255, 255, 0) 89.98%
  );

  background:#FFFFFF24;

  border-radius: 48px;
  box-shadow: 0px 33.25px 33.25px 0px #FFFFFF0D inset;
  transform: translateZ(0);
  
  /* transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1); */
  backdrop-filter: blur(7px);
}

.limit-card-content::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../image/limit_pattern.svg');
  background-repeat: repeat;
  background-size: 100%;
  opacity: 0.3;
  pointer-events: none;
  z-index: -1;
}

.common-page__top-profile-info .limit-card {
    min-height: 70px;
    background: url('../image/bg_blur.png') no-repeat center center / cover;
    backdrop-filter: blur(5px);
    border-left: unset
}

.limit-card-trans_invest {
    cursor: unset !important;
}

.common-page__top-profile-info .limit-card.limit-card-chem_invest {
    display: none;
    @media (max-width: 1166px) {
        display: flex;
    }
}

.common-page__top-profile-info .limit-card.limit-card-fin_invest, .common-page__top-profile-info .limit-card.limit-card-fi_personal {
    display: none;
    @media (max-width: 900px) {
        display: flex;
    }
}

.limit-header {
    min-height: 30px;
    max-height: 48px;
    flex-shrink: 0; 
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.limit-card-content {
    height: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
    padding: 24px 24px 16px 24px;
    overflow: hidden;
    box-sizing: border-box;
}

.limit-cards--collapsed .limit-cards-subcontainer {
    height: 140px;
}
.limit-cards--collapsed .limit-card {
    height: 110px;
}


.limit-card.common-page__top-profile.common-page__top-profile-main {
    padding-right: 64px;
    position: relative;

    @media (max-width: 576px) {
        width: 100%;
        flex: 1 0 auto;
        background: none;
        border-left: none;
    }
}

.limit-card.common-page__top-profile {
    padding-right: 64px;
}

.limit-card.common-page__top-profile::after, .limit-card.common-page__top-profile.common-page__top-profile-main::after {
    content: '';
    position: absolute;
    height: 100%;
    width: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: url('../image/profile-icon.svg') no-repeat right 10px center / 44px 44px;
}

.limit-card.common-page__top-profile.common-page__top-profile-main::after {
    @media (max-width: 576px) {
        background: url('../image/profile-icon.svg') no-repeat center center / 50px 50px;
    }
}

.limit-card.common-page__top-profile.common-page__top-profile-main>.limit-card-content {
    @media (max-width: 576px) {
        display: none;
    }
}

.limit-title, .limit-subtitle, .limit-title-prev, .limit-line {
    color: var(--neutral-white);
    text-decoration: none;
    font-weight: 400;
}

.limit-title {

    font-size: 18px;
    color: var(--neutral-white);
    font-weight: 500;
    font-size: 24px;
    line-height: 90%;
    letter-spacing: 0%;
    font-family: Commissioner;
}


.limit-subtitle {
    margin-top: 4px;
    font-weight: 300;
    font-size: 16px;
    line-height: 110%;
    letter-spacing: 0%;
    margin-bottom: 1rem;
    font-family: Commissioner;

}

.limit-title-prev {
    font-size: 12px;
    line-height: 1.2;
    margin-bottom: 2px;
}

.limit-line {
    display: flex;
    width: 100%;
    align-items: baseline;
    gap: 5px;
    justify-content: flex-start;
    font-family: Commissioner;
    font-weight: 300;
    font-size: 16px;
    line-height: 110%;
    letter-spacing: 0%;
}


.limit-value {
    width: 100%;
    font-size: 16px;
    font-weight: 300;
    line-height: 1;
    white-space: nowrap;
    display: flex;
    align-items: baseline;
}

.limit-label {
    font-size: 12px;
    font-weight: 200;
    line-height: 1;
    opacity: 0.8;
    white-space: nowrap;
}

.limit-source .limit-value {
    font-size: 13px;
}

.progress-linear {
    overflow: hidden;
    position: relative;
    width: 100%;
    min-height: 20px;
    height: 20px;
    gap: 10px;
    border-radius: 25px;
    overflow: hidden;
    background-color: rgba(255, 255, 255, 0.15);
}

.progress-linear__background {
    background-color: rgba(255, 255, 255, 0.2);
    inset: 0;
    position: absolute;
}

.progress-linear__determinate {
    background:rgba(104, 155, 250, 0.8);
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 22px;
    gap: 10px;
    /* transition: width 0.5s ease; */
}

.progress-linear__label {
    position: absolute;
    inset: 0;
    z-index: 1;
    height: 26px;
    display: none;
    align-items: center;
    padding: 0 10px;
    font-size: 11px;
    color: var(--neutral-white);
    white-space: nowrap;
}

.limit-progress {
    grid-area: progress;
    margin: 0;
}

.limit-overdue_debt {
    background-color:var(--rich-dark-red);
    color: var(--neutral-white);
    font-weight: 300;
    font-size: 14px;
    border-radius: 100px;
    padding: 8px 16px;
    white-space: nowrap;
    line-height: 111%;
    font-family: Commissioner;
    align-self: flex-start;
    letter-spacing: 1%;
}

.limit-increase-link {
    color: var(--light-green-new);
    background: none;
    gap: 8px;
    margin-top: 8px;
    cursor: pointer;
    align-self: flex-end;
    font-family: Commissioner;
    font-weight: 600;
    font-size: 14px;
}
