
/* tally */
#voteph-tally-wrap {
  width: 980px;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  align-content: flex-start;
  margin: 0 auto;
  gap: 20px;
}

.voteph-tally-header {
  width: 100%;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  box-sizing: border-box;
  border: 1px solid #B8B8B8;
  padding: 20px 20px;
}

.vt-flex-full {
  width: 100%;
}

.voteph-tally-info {
  width: 100%;
}

.vtc-lbl {
  color: var(--black-33333, #333);
  /* Mallory - Heading 4 */
  font-family: 'Mallory';
  font-size: 16px;
  font-style: normal;
  font-weight: 700;
  padding: 0 0 10px 0;
  width: 100%;
}

.vtc-txt {
  color: var(--black-33333, #333);
  text-align: left;
  /* Mallory - Heading 3 */
  font-family: 'Mallory';
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.voteph-tally-lbl {
  color: var(--Main-Blue, #004C87);
  font-family: 'Mallory';
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.4em;
}

.voteph-tally-summary {
  width: 100%;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
  padding: 40px 0 0 0;
  box-sizing: border-box;
}

.voteph-tally-pd {
  color: var(--black-33333, #333);
  font-family: 'Mallory';
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4em;
  padding: 5px 0;
}

.vt-search {
  width: 420px;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
}

.vt-search input {
  width: 90%;
  height: 32px;
  padding: 0 20px;
  border-radius: 9999px;
  border: 1px solid rgba(184, 184, 184, 0.50);
  background: var(--Inq-Dirty-White, #F3F3F3);
  box-sizing: border-box;
}

.vt-search-icon {
  width: 8%;
}

.vt-search-icon img {
  width: 100%;
  height: auto;
}

.vt-er-count {
  width: 240px;
  border-left: 1px solid #B8B8B8;
  border-right: 1px solid #B8B8B8;
  padding: 0 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  align-content: flex-start;
}

.vt-vote-count {
  width: 200px;
}

.vtc-count {
  width: 140px;
  height: 16px;
  background-color: #dfdfdf;
  border-radius: 20px;
  border: 1px solid #d4d4d4;
}

.vtc-progbar {
  width: 79.9%;
  height: 16px;
  background-color: #004C87;
  border-radius: 20px 0 0 20px;
}

.vtc-txt2 {
  color: var(--black-33333, #333);
  font-family: 'Mallory';
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
  padding: 8px 0 0 0;
}

/* Senatorial */
.voteph-sen-tally {
  height: auto;
  border: 1px solid #B8B8B8;
  box-sizing: border-box;
  padding: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
  gap: 20px;
}

.vt-flex-half {
  width: 48.8%
}

.vt-hf-lbl {
  color: var(--black-33333, #333);
  /* Mallory - Heading 4 */
  font-family: 'Mallory';
  font-size: 18px;
  font-style: normal;
  font-weight: 700;
  padding: 0 0 10px 0;
  border-bottom: 3px solid #004C87;
  width: 100%;
}

.sen-child {
  width: 100%;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  align-content: flex-start;
  box-sizing: border-box;
}

.sent-img {
  width: 13%;
  height: auto;
  aspect-ratio: 1/1;
  background-color: #ffffff;
  border-radius: 100%;
  overflow: hidden;
  opacity: 0; /* Start hidden */
  transform: scale(0.8); /* Start slightly smaller */
  transition: opacity 0.5s ease, transform 0.5s ease; /* Smooth transition */
}

/* When the image is loaded, make it visible */
.sent-img.loaded {
  opacity: 1;
  transform: scale(1); /* Scale back to normal size */
}

.sent-img img {
  width: 100%;
  object-fit: cover;
}

.sent-data {
  width: 83%;
  font-family: 'mallory';
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  align-content: flex-start;
  letter-spacing: 0.02em;
}

.sent-rank {
  border-radius: 100%;
  background-color: #1A1A1B;
  color: #ffffff;
  font-size: 13px;
  text-align: center;
  width: 25px;
  height: 25px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.sent-name {
  width: 90%;
  font-size: 18px;
  color: #333333;
}

.sent-votes {
  width: 100%;
  font-size: 18px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #333333;
  padding: 5px 0 10px 0;
  transition: color 0.3s ease, transform 0.3s ease;
}

.sent-bar {
  width: 100%;
  height: 5px;
  background-color: #d4e4e8;
}

/* Apply the animation to .sent-bar-prog */
.sent-bar-prog {
  height: 5px;
  width: 0;
  background-color: #00C0F3;
}

@keyframes dynamicFill {
  from {
      width: 0;
  }
  to {
      width: var(--target-width);
  }
}

.vt-load-more {
  width: 100%;
  text-align: center;
  font-family: 'mallory';
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0;
  font-size: 16px;
}

.vt-load-more span:hover {
  background: #0B72B5;
  transition: 0.5s;
}

.vt-load-more span {
  border-radius: var(--regular-8, 8px);
  background: var(--Main-Blue, #004C87);
  padding: 14px 28px;
}

.vt-load-more a, .vt-load-more a:visited {
  color: #ffffff;
  text-decoration: none;
}

.voteph-party-tally {
  height: auto;
  border: 1px solid #B8B8B8;
  box-sizing: border-box;
  padding: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
  gap: 20px;
}

.pt-perct {
  color: var(--Main-Blue, #004C87);
  text-align: center;
  font-family: 'Mallory';
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
}

/* local */
#vt-ph-local {
  height: auto;
  border: 1px solid #B8B8B8;
  box-sizing: border-box;
  padding: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
  gap: 20px;
}

#vt-ph-control {
  width: 100%;
  height: auto;
  box-sizing: border-box;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-around;
  align-content: flex-start;
  gap: 20px;
  font-family: 'mallory';
  font-size: 16px;
  font-style: normal;
  font-weight: 700;
  text-decoration: underline;
}

#vt-ph-control a, #vt-ph-control a:visited {
  color: #333333;
}

.vtphl-list {
  height: auto;
  box-sizing: border-box;
  padding: 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: flex-start;
  align-content: flex-start;
  gap: 20px;
  width: 100%;
  display: none;
  opacity: 0;
  transition: max-height 0.4s ease-in-out, opacity 0.4s ease-in-out;
  overflow: hidden;

}

.vtphl-list.active {
  display: flex;
  max-height: 1000px; /* Adequate max height for the content */
  opacity: 1;
}


.vtphl-c {
  font-family: 'mallory';
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  align-content: flex-start;
  width: 23%;
}

.vtphl-c span {
  font-weight: 700;
  color: #004C87;
}

.vtphl-c a, .vtphl-c a:visited {
  color: #333333;
  text-decoration: none;
}

.vtphl-c a:hover {
  color: #0B72B5;
  transition: .5s;
}


/* mobile */
@media only screen and (min-width: 600px) and (max-width: 768px){
    /* tally */
    #voteph-tally-wrap {
      width: 93%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      flex-direction: row;
      justify-content: space-between;
      align-items: flex-start;
      align-content: flex-start;
      margin: 0 auto;
      gap: 20px;
    }
    
    .voteph-tally-header {
      width: 100%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      justify-content: space-between;
      box-sizing: border-box;
      border: 1px solid #B8B8B8;
      padding: 20px 20px;
    }
    
    .vt-flex-full {
      width: 100%;
    }
    
    .voteph-tally-info {
      width: 100%;
    }
    
    .voteph-tally-summary {
      width: 100%;
      justify-content: center;
      gap:30px
    }
    
    .vt-search-icon {
      width: 8%;
    }
    
    .vt-search-icon img {
      width: 100%;
      height: auto;
    }
    
    .vt-vote-count {
      width: 100%;
      text-align: center;
    }
    
    .vtc-txt {
      text-align: center;
    }
    
    /* Senatorial */
    
    .vt-flex-half {
      width: 100%;
    }
    
    .vt-hf-lbl {
      font-size: 22px;
    }
    
    .sen-child {
      width: 100%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      align-content: flex-start;
      box-sizing: border-box;
    }
    
    .sent-img {
      width: 20%;
    
    }
    
    .sent-data {
      width: 74%;
      font-family: 'mallory';
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      align-content: flex-start;
      letter-spacing: 0.02em;
    }
    
    .sent-rank {
      border-radius: 100%;
      background-color: #1A1A1B;
      color: #ffffff;
      font-size: 13px;
      text-align: center;
      width: 25px;
      height: 25px;
      display: flex;
      justify-content: center;
      align-items: center;
    }
    
    .sent-name {
      width: 85%;
      font-size: 18px;
      line-height: 1.4em;
    }
    
    .vtphl-c {
      font-family: 'mallory';
      font-size: 16px;
      font-style: normal;
      font-weight: 400;
      display: flex;
      flex-wrap: wrap;
      align-items: flex-start;
      justify-content: space-between;
      align-content: flex-start;
      width: 100%;
    }
        
    }
    
    /* mobile */
    @media only screen and (min-width: 320px) and (max-width: 599px){

    
    /* tally */
    #voteph-tally-wrap {
      width: 93%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      flex-direction: row;
      justify-content: space-between;
      align-items: flex-start;
      align-content: flex-start;
      margin: 0 auto;
      gap: 20px;
    }
    
    .voteph-tally-header {
      width: 100%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      justify-content: space-between;
      box-sizing: border-box;
      border: 1px solid #B8B8B8;
      padding: 20px 20px;
    }
    
    .vt-flex-full {
      width: 100%;
    }
    
    .voteph-tally-info {
      width: 100%;
    }
    
    .voteph-tally-summary {
      width: 100%;
      justify-content: center;
      gap:30px
    }
    
    .vt-search-icon {
      width: 8%;
    }
    
    .vt-search-icon img {
      width: 100%;
      height: auto;
    }
    
    .vt-vote-count {
      width: 100%;
      text-align: center;
    }
    
    .vtc-txt {
      text-align: center;
    }
    
    /* Senatorial */
    
    .vt-flex-half {
      width: 100%;
    }
    
    .vt-hf-lbl {
      font-size: 22px;
    }
    
    .sen-child {
      width: 100%;
      height: auto;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      align-content: flex-start;
      box-sizing: border-box;
    }
    
    .sent-img {
      width: 20%;
    
    }
    
    .sent-data {
      width: 74%;
      font-family: 'mallory';
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      align-content: flex-start;
      letter-spacing: 0.02em;
    }
    
    .sent-rank {
      border-radius: 100%;
      background-color: #1A1A1B;
      color: #ffffff;
      font-size: 13px;
      text-align: center;
      width: 25px;
      height: 25px;
      display: flex;
      justify-content: center;
      align-items: center;
    }
    
    .sent-name {
      width: 85%;
      font-size: 18px;
      line-height: 1.4em;
    }
    
    .vtphl-c {
      font-family: 'mallory';
      font-size: 16px;
      font-style: normal;
      font-weight: 400;
      display: flex;
      flex-wrap: wrap;
      align-items: flex-start;
      justify-content: space-between;
      align-content: flex-start;
      width: 100%;
    }
    
    }