html{
--smc:#ffc20e;
--grc3:#f68d9e;
--grc4:#ed3c7c;
--grc5:#b053a0;
--grc6:#b80b4d;
--winner:#ee2f4e; 
}
body{
  background-color:#fbffff;
  background-image: url(../img/d-bg.webp);
  background-size: 100%;
  background-repeat: no-repeat;
  background-attachment: fixed;
}
.toggle-btn {
  background: rgb(208 233 255)!important;
}
.publish {
  font-size: 0.9em;
  padding: 1em 0;
  margin: 1.5em auto 0 auto;
  border-top: 2px dotted #013d64;
}
.publish .date {
  padding-right: 1em;
  border-right: 1px solid #fff;
}
p {
  word-wrap: break-word;
  word-break: break-word;
  white-space: normal;
}
.main-title{
  font-size: 3rem;
  font-weight: 900;
  text-align: center;
}
.main-title-s{
  text-align: center;
    color: #013d64;
    font-weight: 900;
    font-size: 1.6rem;
    padding: 0.3em;
    margin-bottom: 0;
}
.landing-wrap{
  height: 100dvh;
  margin-top: 5em;
  width: 50%;
}
#map-container {
  flex: 1;
  padding-right: 20px;
  position: relative;
}

.svg-map-container {
  position: relative;
}
.map-wrap{
  margin: auto;
  width: 90%;
}
.map-wrap-first-child{
  margin-top: -4em;
}
.map-bg{
  border: 2px dotted #ccc6e3;
  background-color: #fff;
  margin: 1em 3em;
  border-radius: 10px;
}
.map-wrap h2{
  font-weight: 700;
}
.indicator{
  margin: 0 0 1em 0;
  font-size: 0.9rem;
}
.indicator-img{
  width: 35px;
  cursor: pointer;
  animation: rotate 0.5s linear infinite;
}
.keypoint{
  color: var(--theme-ui-colors-secondary);
  font-weight: 800;
}
.keypoint b{
  color: #fff;
  background-color: var(--theme-ui-colors-secondary);
  font-weight: 900;
  padding: 0.1em 0.2em;
  margin-right: 0.2em;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    -moz-transform: translateY(0);
    -ms-transform: translateY(0);
    -webkit-transform: translateY(0);
    transform: translateY(0);
  }
  40% {
    -moz-transform: translateY(-30px);
    -ms-transform: translateY(-30px);
    -webkit-transform: translateY(-30px);
    transform: translateY(-30px);
  }
  60% {
    -moz-transform: translateY(-15px);
    -ms-transform: translateY(-15px);
    -webkit-transform: translateY(-15px);
    transform: translateY(-15px);
  }
}
.fa-5x {
  font-size: 3em;
}
i {
  display: block;
  color: #013d64;
}
.arrow {
  animation: bounce 2s infinite;
  width: 40px;
  margin: auto;
  padding-top: 1.5em;
}
.constituency-row p{
  margin-bottom: 0;
}
.map{
padding: 1em 1em 0;
}
.voter{
    padding: 0.5em;
}
.exvoter{
  border-right: 1px solid #999;
}
.voter-number{
  width: 100%;
  border: 1px dotted #999;
  border-radius: 10px;
}
/* Show only the active map */
.map.active {
  display: block;
  z-index: -1;
}
.main{
  border-radius: 10px;
    padding: 1em 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    background-color: #ffffffad;
}
#info-panel {
  align-content: center;
  padding: 2em 3em 1em 0;
}
#constituency-info h2{
  border-bottom: 2px dotted #999;
  margin: 0 0.5em 0 0;
  padding-bottom: 0.5em;
}
.dotted-line {
  border-bottom: 2px dotted #999;
  padding-bottom: 5px;
}


.grc5-highlight {
  fill: #b053a0; /* Default color */
  transition: fill 0.3s;
}

.grc5-grp.hover .grc5-highlight {
  fill: #5b257f; /* Hover color */
}
.grc5-grp.hover .smc-highlight {
  fill: #ff8e00; /* Hover color */
}
.st2{stroke:#FFFFFF;stroke-miterlimit:10;}

.grc5-highlight:hover{
  fill: #5b257f;
  cursor: pointer;
}
.grc4-highlight:hover{
  fill:#af025c;
  cursor: pointer;
}
.smc-highlight:hover{
  fill: #ff8e00;
  cursor: pointer;
}
.highlight-svg .grc5-highlight {
  fill: #b053a0;
}

.highlight-svg:hover .grc5-highlight {
  fill: #5b257f;
}

.grc5-highlight {
  pointer-events: all;
}
.constituency-row {
  justify-content: center; 
  align-items: end;
  padding: 0 0 10px 0;
  margin: 0 0 0.2em 0;
}
/* CSS for Bar Chart */
.bar-chart {
  display: flex;
  align-items: center;
  padding: 1.5em 0 0;
  background-color: #fff;
}
.bar-container-grey{
position: relative;
background-color: #bdbdbd;
display: flex;
height: 20px;
width: 240px;
align-items: center;
}
.party-logo {
  flex: 0 0 50px; 
  display: flex;
  justify-content: center;
  align-items: center;
}

.party-logo img {
  width: 40px; 
  height: auto;
}
.ge-icon{
  margin: 1.5em 0 0em;
}
.ge-icon-img{
  width: 9%;
  margin-bottom: 0;
}
.bar-container {
  flex: 1;
  position: relative;
  height: 20px;
  background-color: #bdbdbd;
  display: flex;
  align-items: center;
}

.bar {
  height: 100%;
}

.bar.red {
  background-color: #e90044; 
}

.bar.grey {
  background-color: #bdbdbd; 
}

.margin-line {
  position: absolute;
  left: 50%; 
  transform: translateX(-50%);
  border-left: 2px dashed #fff;
  height: 100%;
  display: flex;
  align-items: center;
}

.margin-line span {
  position: absolute;
  top: -30px;
  font-weight: 900;
  font-size: 20px;
  right: -37px;
}

.vote-info {
  width: 100%;
  display: flex;
  background-color: #fff;
  justify-content: space-between; 
}

.vote-info p {
  font-size: 14px;
  margin: 0.2em 0.2em 0;
}
.voto-info-grey p{
  margin: 0.2em 1.5em 0!important;
}
.eb-cate{
  padding: 1em;
  line-height: 1.2;
  color: #fff;
}
.eb-cate b{
  font-size: 1.3rem;
}
.eb-smc{
  border: 1px solid #ffc20e;
  background-color: #ffc20e;    
  color: #000;
}
.eb-grc4{
  border: 1px solid #ed3c7c;
  background-color: #ed3c7c;
}
.eb-grc5{
  border: 1px solid #b053a0;
  background-color: #b053a0;
}
.p-seat{
  border: 1px solid #999;
  color: #000;
}
.list-chart{
  background: #ffffffcf!important;
  border-radius: 10px;
  padding: 2em 3em;
  margin: 0 1em;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); 
}
.mobile-tab-container {
  margin-top: 20px;
}
.mobile-tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
}
.mobile-tab {
  padding: 10px 20px;
  background-color: #ffffff;
  border: #f48580 solid 1px;
  cursor: pointer;
  color: #000;
  margin: 0 5px;
  border-radius: 5px;
  line-height: 1.4;
  text-align: center; 
}

.mobile-tab:hover {
  background-color: #003d64;
  border: #003d64 solid 2px;
  color: white;
}

.mobile-tab.active {
  background-color: #e90044;
  border: #e90044 solid 2px;
  color: white;
}

.mobile-cards {
  display: flex !important; /* Force flex display */
  justify-content: flex-start; /* Ensure horizontal alignment */
  align-items: flex-start; 
  overflow-x: auto; 
  white-space: nowrap; 
  padding: 10px; 
  scroll-behavior: smooth;
}

.mobile-cards::-webkit-scrollbar {
  display: none;
}

.mobile-cards::-webkit-scrollbar-thumb {
  display: none; 
}
.mobile-card {
  display: inline-block;
  background-color: #fff;
  margin: 0 10px;
  width: 90%;
  max-width: 350px;
  text-align: center;
  border-radius: 10px;
  flex-shrink: 0; 
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); 
}
.constituency-detail{
  margin: 0 1em;

}
#constituency-info{
  font-family: roboto;
}
.constituency-map{
  margin: auto;
  padding: 0;
}
.map-m{
  width: 100%;
}
.voters{
  margin: 3em 0 0 0;
}
.voters p{
  margin: 0;
}
.voter-h p{
  margin: 0 0 0.2em;
}
.voter p small{
  color: #777;
}
.voters h4{
  margin: 0.2em 0 0;
  text-wrap: auto;
}
.instruction{
  padding: 1em;
}
.percentage{
  font-size: 0.8rem;
}
.opinion{
  text-align: left;
  margin: 0 0 0.8em 0;
}
.opinion p{
  margin: 0 1em 1em 1em;
}
.grc-grp{
  padding: 0.5em 0 0;
  line-height: 1.8;
}
.c-bg{
  padding: 0.2em 0.5em;
  vertical-align: bottom;
  color: #fff!important;
}
.highlight-bg{
  color: #fff;
  padding: 0.1em 0.5em;
  margin: 0 0.3em;
}
.grc5-bg{
  background-color: #b053a0;
}
.grc4-bg{
  background-color: #ed3c7c;
}
.smc-bg{
  background-color: #ffc20e;
  color: #000;
}
.list-group-item {
  background-color:#ffffff00;
  border: none;
}
.content{
  width: 50%;
  padding: 2em 0;
}
.content h2{
  font-weight: 700;
  margin: 0 0 1em 0;
}
.read-more{
  color:#a81d38;
  border-bottom: 1px solid #a81d38;
}
.read-more:hover{
  color:#0f3e65;
  background-color: #fff;
  border-bottom: 1px solid #0f3e65;
}
.key-points {
  display: inline-block; 
  width: 30px; 
  height: 30px; 
  border-radius: 50%; 
  background-color: #003866; 
  margin-right: 0.5em;
  color: #fff; 
  text-align: center; 
  line-height: 1.8; 
  font-weight: bold;
  font-size: 16px; 
}
.tag{
  font-size: 0.8em;
  font-weight: normal;
  margin: 5em auto;
  display: block;
  text-align: center;
  position: relative;
  }
  .tag a{
    color: #000;
    border: 1px solid #003e64;
    padding: 0.4em 1em 0.3em 1em;
    margin: 0.3em 0.3em 0.3em 0;
    color: var(--theme-ui-colors-text-secondary);
    background: var(--theme-ui-colors-white);
    border-radius: 50px;
    border: 1px solid #ccc;
    display: inline-block;
  }
@keyframes rotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(15deg); }
}
@keyframes moveLeftRight {
  0% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(-20px);
  }
  100% {
    transform: translateX(0);
  }
}
@media (min-height: 600px) and (max-height: 750px) and (orientation: landscape) {
  .map-wrap-first-child {
    margin-top: 0;
}
.landing-wrap {
  margin-top: 4em;
}
}
@media (min-width: 200px) and (max-width: 1000px) {
  body{
    background-color:#fbffff;
    background-image: url(../img/m-bg.webp);
  }
  #info-panel {
    padding: 1em 2em;
    margin-top: 5em;
  }
  .dotted-line{
    border-bottom: 1px dotted #777;
    border-top:none;
  }
  .party-logo img {
    width: 30px; 
    height: auto;
  }
  .vote-info {
    margin: 0;
    padding-bottom: 0.5em;
  }
  .voter p{
    margin: 0;
  }
  .vote-info p {
    font-size: 12px;
    margin: 0.2em 1.5em;
}
  .margin-line span {
    top: -28px;
    font-size: 18px;
    font-family: roboto;
  }
.keypoint{
  font-weight: 600;
}
.margin-line {
  border-left: 2px solid #fff;
}
  .landing-wrap {
    width: 90%;
    height: auto;
  }
  .content {
    width: 95%;
  }
  .voter-info{
    border: 1px dotted #777;
    margin: 0 1em 0.5em;
    border-radius: 10px;
  }
  .content h2 {
    margin: 0 0 0.5em 0;
  }
  .indicator{
    margin: 1em 0 0 0;
      font-size: 0.8rem;
      margin: auto;
      border-radius: 5px;
      animation: moveLeftRight 2s infinite;
      cursor: pointer;
  }
  .indicator-img{
    animation: none;
  }
  .constituency-map {
    padding: 1em 0 0 0;
  }
  .constituency-grc5map {
    padding: 2em 1em 0;
}
  .ge-icon {
    margin: 0 0.5em 0.2em;
  }
  .ge-icon-img {
    width: 20%;
  }
  .arrow {
  width: 30px;
  }
  #constituency-info h2 {
    margin: 0 0.2em 0;
  }
  .bar-chart {
    padding: 2em 1em 0;
  }
  .voter h4{
    margin: 0;
  }
}
