/* Completely Redesigned Modern Light Theme for AdvertiseConnect- AS */

/* Global Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}
nav.navbar{
    background:#fff !important;
}
body {
    background-color: #f7f9fc;
    color: #333;
    line-height: 1.8;
}

/* Layout */
.wrapper {
    display: grid;
    grid-template-columns: 250px auto;
    grid-gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px;
}

/* Sidebar */
.sidebar {
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.sidebar ul {
    list-style: none;
    padding: 0;
}

.sidebar ul li {
    margin: 15px 0;
}

.sidebar ul li a {
    text-decoration: none;
    color: #007bff;
    font-weight: 500;
    transition: color 0.3s;
}

.sidebar ul li a:hover {
    color: #0056b3;
}

/* Main Content */
.main-content {
    background: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.05);
}
#maincontent p,#maincontent ul,#maincontent form,#maincontent div,#maincontent span{
    font-size: 18px;
    padding-right: 12px;
    margin-bottom: 10px;
    /* margin-top: 10px; */
}
#maincontent div#slider div{
    padding-right: 0px;
    margin-bottom: 10px;
    
}

/* Forms */
form {
    background: #ffffff;
    padding: 25px;
    padding-bottom:25px;
    border-radius: 10px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom:120px;
}

input, textarea {
    width: auto;
    padding: 2px;
    border: 2px solid #ddd;
    border-radius: 6px;
    background: #f9f9f9;
    transition: border 0.3s;
    font-weight: bold !important;
    margin-top: 12px;
}
input[type="checkbox"]{
    max-width: 35px;
}
.form-check input[type=checkbox], .form-check input[type=radio]{
    max-width: 15px;
    margin-top: .5em;
}
input[type=radio]{
    width:auto !important;
}
input[type="submit"]{
    max-width: 225px;
}
input:focus, textarea:focus {
    border-color: #007bff;
    background: #ffffff;
}  
  
  @media (max-width: 768px) {
    input[type="submit"] {
        width: 100%;              
        padding: 12px 16px;        
        font-size: 15px !important;           
        line-height: 1.4;         
        box-sizing: border-box;   
        border-radius: 6px;        
        border: none;             
        cursor: pointer;         
        width: auto;           
        max-width: 250px !important;
        padding: 10px 20px;      
    }
    #promoactform div.promoBoxSb{
        display: block;
    }
    #promoactform div.promoBoxSb input[type=submit]{
        float: inline-end;
    }
  }
#promoactform{margin-bottom: 45px;}
.promoBoxSb {display:flex;align-items: center;}
.promoBoxSb input[name="PromoCode"]{
    max-width: 250px;
    margin:0 15px;
}
.promoBoxSb input[name="apply"]{
    margin-top:0px;
}
.promoBoxSb input[name="apply"],.promoBoxSb input[name="PromoCode"]{
    padding:0px 10px;
}
.optionAdBalanceHeader{display:inline-block;min-width: 150px; text-align: right;margin-right: 8px;}

.optionAdBalanceHeader:nth-child(odd) {
    background-color: #dee2e6;
  }
  
.optionAdBalanceHeader:nth-child(even) {
    background-color: #fff;
  }
.optionAdBalanceText{display:inline-block}

#service_table.dataTable, #auto_table.dataTable,#results_table {
    font-size:16px;
    height: 133px !important;
}
table.dataTable tr td:nth-child(2){
    white-space:nowrap;

}

.page-item.active .page-link{
    z-index: 1px !important;
}
/* Buttons */
button {
    background: #007bff;
    color: #ffffff;
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    transition: transform 0.3s, box-shadow 0.3s;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

/* Card Style */
.card {
    background: #ffffff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Footer */
footer {
    text-align: center;
    padding: 20px;
    background: #ffffff;
    margin-top: 40px;
    box-shadow: 0 -2px 6px rgba(0, 0, 0, 0.1);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .wrapper {
        grid-template-columns: 1fr;
    }
    .sidebar {
        display: flex;
        flex-direction: row;
        justify-content: space-around;
    }
    

}

@media only screen and (max-width: 600px) {
    ul{margin-left:25px !important; }
}

#showingResults, #wrapper_links #maincontent ul.pagination.flex-wrap   { display:float; margin:25px 0px; }


#myCarousel ul.carousel-indicators.list-inline {
    display: grid;
    grid-template-columns: repeat(7, 1fr); /* 7 per row on desktop */
    gap: 3px;
    list-style: none;
    padding: 0;
    margin: 0;
}
#myCarousel .carousel-indicators.list-inline li {
    width: 66px;
    height: 50px;
    border-radius: 2px;
    overflow: hidden;
    margin: 2px;
    
}

@media (max-width: 768px) {
    #myCarousel .carousel-indicators.list-inline li {
        width: 40px;
        height: 30px;
}
    #myCarousel ul.carousel-indicators.list-inline  {
      
      grid-template-columns: repeat(5, 1fr); /* 5 per row on mobile */
    }
  }
 
#youtube-videos {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start; /* Left alignment */
    gap: 16px;
    padding: 0;
    margin: 0;
}

.video-wrapper {
    width: calc(50% - 8px); /* 2 per row */
    position: relative;
    aspect-ratio: 1 / .70; /* Enforce perfect square */
    overflow: hidden;
    background-color: #000; /* Optional fallback */
    box-sizing: border-box;
}

/* If aspect-ratio is not supported (fallback) */
.video-wrapper::before {
    content: "";
    display: block;
    padding-top: 100%; /* Maintains square if aspect-ratio is not supported */
}

.video-wrapper iframe,
.video-wrapper > div {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}


#myCarousel .carousel-inner .carousel-item {
    position: relative;
    width: 100%;
    padding-top: 100%; /* Makes it square */
    overflow: hidden;  
    background-size: 90% auto !important;
    
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

#myCarousel .carousel-inner .carousel-item img {
    display: none; /* Hide the original img tag */
}

#myCarousel .carousel-inner .carousel-item::before {
    content: "";
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%; 
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    
    
}
#myCarousel {max-width: 600px; ;}
#myCarousel .carousel-inner {
    max-width: 600px;   
    max-height: 560px;
}  
.carousel-control-prev{
    left:-45px;
}
.carousel-control-next{
    right:-45px;
}

table.table-striped tr.even,table.table-striped tr.odd, table.table-striped td:first-child{
    min-height: 125px !important;
}

table.table-striped td:first-child{
    min-width: 167px;
    height:125px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    transition: background-size 0.6s ease;
    border:2px solid rgb(222, 226, 230);    
    border-right:0px;
    border-left:0px;
}

table.table-striped tr.odd td:first-child{
    border:5px solid rgba(0,0,0,.05);
    border-right:0px;
    border-left:0px;
}
table.table-striped tr.even td:first-child{
    border:2px solid rgb(222, 226, 230);
    border-right:0px;
    border-left:0px;
}





table.table-striped td:hover {
    background-size: 150%; /* Zoom in */
}


table.table-striped td  a{
  z-index:1;
  position:relative;
}
  
  td a.zoom {
    display: block;
    width: 100%;
    height: 100%;
  }

  table.table-striped a.zoom {
    display: block;
    width: 100%;
    height: 100%;
    transition: transform 0.4s ease;
    transform-origin: center center;
  }
  table.table-striped {
   
    position: relative;
    overflow: hidden;
  }
   
  table.table-striped::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: transform 0.4s ease;
    z-index: 0;
  }
   
  table.table-striped:hover::before {
    transform: scale(1.5);
    z-index: 1;
  }
   
  table.table-striped a.zoom {
    display: block;
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    /* min-height: 250px; */
  }
  


/* Stack to 1 per row on small screens */
@media (max-width: 600px) {
    .video-wrapper {
        width: 100%;
    }
    .table.table-striped td{
        height: 200px;
    }
    img.autopic{
        height: 225px !important;
    }
} 

table[id^="service_table_"]  td:first-child a,table[id^="listing_table_"]  td:first-child a, table[id^="auto_table_"]  td:first-child a{
    position:absolute;
    height:100%;
    width:100%;
}

table[id^="service_table_"] td, table[id^="listing_table_"] td{
    font-size:.85em;
} 


table[id^="service_table_"] thead th, table[id^="listing_table_"] thead th, table[id^="auto_table_"] thead th{
    font-size:.75em;
} 
 
 
table[id^="listing_table_"] tr td:first-child, table[id^="service_table_"] tr td:first-child, table[id^="auto_table_"] tr td:first-child{
    width: 170px !important;
    overflow: hidden;
     
}


@media (max-width: 935px) and (orientation: landscape)  {
    
    table.table-striped a.zoom, a.listingImg{ 
            height: 260px;  
    }

    

 
table[id^="listing_table_"] tr td:first-child, 
table[id^="service_table_"] tr td:first-child, 
table[id^="auto_table_"] tr td:first-child,
table[id^="listing_table_"] tr td:first-child a, 
table[id^="service_table_"] tr td:first-child a, 
table[id^="auto_table_"] tr td:first-child a{
    height: 260px;   
     
}
    

    table.table.table-striped ul.dtr-details li{
        margin-left: 20px; 
    }
}



.btn.fill-button {
    border: 1px solid #1d75bb;
    color: #fff;
    padding: 14px 16px 12px;
    border-radius: 6px;
    font-size: 15px;
    position: relative;
    font-weight: 500;
    background-color: #1d75bb;
    position: relative;
}


.btn.fill-button:before {
    content: "";
    position: absolute;
    width: 0%;
    left: 0;
    top: 0;
    height: 100%;
    transition: all 0.5s ease;
    background-color: #fff;
    border-radius: 6px;
}

.btn.fill-button:hover:before {
    width: 100%;
    transition: all 0.5s ease;
}

.btn.fill-button:hover span {
    color: #1d75bb;
    position: relative;
    z-index: 1;
}

.btn.transparent-button:before {
    content: "";
    position: absolute;
    width: 0;
    height: 102%;
    background-color: #1d75bb;
    left: 0;
    top: -1px;
    border-radius: 6px;
    transition: all 0.5s ease;
}
.navbar-light .navbar-toggler {
min-width: 160px;
}

.pagebtnheader {display:flex;width:100%; flex-direction: row-reverse}
