.search-inv{
    width: 300px !important;
    position: absolute;
    right: 20px;
    top: 13px;
    height: 40px !important;
    background: var(--background) !important;
}

.create-fb-ad{
    width:90px !important;
}

.pagination-cont{
    position: absolute;
    left: 5px;
    bottom: 90px;
    width: 300px;
    padding: 10px;
    border-radius: 4px;
    text-align: left;
}

.page-left{
    font-size: 20px;
    opacity: .7;
    margin-right: 20px;
    cursor: pointer;
}

.page-right{
    font-size: 20px;
    opacity: .7;
    margin-left: 20px;
    cursor: pointer;
}

.current{
    background: var(--themeColor);
    padding: 5px 10px;
    border-radius: 100px;
    color: var(--clicked) !important;
}

.pagination-nav{
    position:relative;
    top:-2px;
}

.pagination-nav span{
    font-size: 14px;
    font-weight: 600;
    opacity: .9;
    position: relative;
    top: 0;
    margin: 4px;
    color: var(--text);
    cursor: pointer;
}

.create-new-strategy-btn{
    font-size: 12px !important;
    position: absolute;
    right: 20px;
    top: 17px;
}

.create-strategy-mod{
    width: 500px;
    height: 350px;
    margin: auto;
    top: 15vh;
}

.cs-title{
    font-size: 20px;
    margin-bottom: 5px;
    margin-top: 10px;
}

.cs-text{
    font-weight: 500;
    opacity: .7;
    margin-bottom: 20px;
}

.strategy-input{
    height: 100px;
    resize: none;
}

.sub-strategy{
    position: absolute;
    right: 5%;
    bottom: 30px;
    width: 91%;
    height: 55px;
}

.strategy-mess{
    font-size: 13px;
    position: relative;
    left: 0px;
    top: 10px;
    font-style: italic;
    font-weight: 500;
}

.set-fb-budget{
    position: relative;
    float: right;
    font-size: 12px !important;
}

.new-fb-budget{
    width: 90% !important;
    position: relative;
    left: 5%;
    border: 1px solid var(--border) !important;
}

.total-inv-count{
    margin-top: -1px;
}

.toggle-fb {
    display: none;
}

.toggle-label-fb {
    position: relative;
    width: 50px;
    height: 25px;
    background-color: var(--toggleLight);
    border-radius: 50px;
    cursor: pointer;
    margin-right: 10px;
    transition: background-color 0.3s ease;
}

.toggle-label-fb::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 21px;
    height: 21px;
    background-color: var(--toggleDark);
    border-radius: 50%;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

/* ON state */
.toggle-fb:checked + .toggle-label-fb {
    background-color: var(--toggleDark);
}

.toggle-fb:checked + .toggle-label-fb::before {
    transform: translateX(25px);
    background-color: var(--toggleLight);
}

.toggle-text {
    position: absolute;
    color: var(--text);
    margin-left: 5px;
    font-size:15px;
}

.toggle-facebook{
    position: absolute;
    width: 250px;
}
.fb-ad-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    justify-items: stretch;
    justify-content: stretch;
    min-height: 400px;
  }

  .fb-ad-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    border: 1px solid #e4e6eb;
    font-family: system-ui, Arial, sans-serif;
    display: flex;
    flex-direction: column;
    min-width: 0;
    height: 100%;   /* <-- This is the key! */
  }

  .fb-ad-header {
    display: flex;
    align-items: center;
    padding: 16px 16px 8px 16px;
  }

  .fb-avatar{
    font-size: 40px;
  }

  .fb-page-name {
    font-weight: bold;
    color: #1c1e21;
    font-size: 15px;
    line-height: 18px;
    margin-left: 20px;
  }
  .fb-sponsored {
    color: #606770;
    font-size: 12px;
    margin-top: 2px;
    margin-left: 20px;
  }
  .fb-menu {
    margin-left: auto;
    font-size: 14px;
  }
  
  .fb-ad-copy {
    padding: 8px 16px 0 16px;
    font-size: 15px;
    color: #050505;
    line-height: 20px;
  }
  
  .fb-ad-image {
    margin: 12px 0 0 0;
    width: 100%;
    aspect-ratio: 4/3;
    background: #e4e6eb;
    overflow: hidden;
  }
  .fb-ad-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }
  
  .fb-ad-cta {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: #f0f2f5;
    border-top: 1px solid #e4e6eb;
    margin-top: auto; 
  }

  .fb-ad-link {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }
  
  .fb-url {
    color: #65676b;
    font-size: 13px;
  }
  .fb-headline {
    color: #050505;
    font-size: 15px;
  }
  
  .fb-shop-btn {
    font-weight: bold;
    border-radius: 6px;
    text-decoration: none;
    font-size: 15px;
    margin-left: 16px;
    transition: background .2s;
  }
  .fb-shop-btn:hover {
    background: #145db2;
  }
  
  .fb-ad-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding: 12px 18px 14px 18px;
    border-top: 1px solid #e4e6eb;
    font-size: 14px;
    color: #65676b;
    gap: 8px;
  }
  
  .fb-ad-footer span {
    flex: 1 1 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-size: 13px;
  }
  
  .fb-metric-val {
    font-weight: bold;
    color: #1c1e21;
    font-size: 15px;
    margin-bottom: 2px;
    line-height: 1.15;
  }
  
  .fb-metric-lab {
    font-size: 12px;
    color: #606770;
    line-height: 1.1;
    font-weight: normal;
  }
  