/* ===========================
   M.I Motor Sales
   Luxury Black & Gold Theme
=========================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:'Poppins',sans-serif;
}

html{
    scroll-behavior:smooth;
}

body{
    background:#0A2472;
    color:#fff;
    line-height:1.6;
}

/* Header */

header{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:20px 8%;
    background:#0A2472;
    position:sticky;
    top:0;
    z-index:1000;
    box-shadow:0 5px 20px rgba(0,0,0,.5);
}

.logo{
    display:flex;
    align-items:center;
    gap:15px;
}

.logo img{
    width:80px;
}

.logo h1{
    color: #ffba08;;
    font-size:30px;
    margin-bottom:3px;
}

.logo p{
    color:#bfbfbf;
    font-size:13px;
}

nav ul{
    display:flex;
    list-style:none;
    gap:30px;
}

nav ul li a{
    text-decoration:none;
    color:#fff;
    font-weight:500;
    transition:.3s;
}

nav ul li a:hover{
    color:#ffba08;
}

/* Hero */

.hero{
    height:90vh;
    background:url("cars/hero.jpg") center center/cover no-repeat;
    position:relative;
}

.overlay{
    position:absolute;
    inset:0;
    background:rgba(0,0,0,.65);
    display:flex;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    text-align:center;
    padding:20px;
}

.overlay h2{
    font-size:60px;
    color:#d4af37;
    margin-bottom:20px;
}

.overlay p{
    font-size:22px;
    margin-bottom:40px;
}

.buttons{
    display:flex;
    gap:20px;
    flex-wrap:wrap;
}

.gold-btn,
.black-btn{
    padding:15px 35px;
    border-radius:40px;
    text-decoration:none;
    font-weight:600;
    transition:.3s;
}

.gold-btn{
    background:#d4af37;
    color:#000;
}

.gold-btn:hover{
    transform:translateY(-5px);
    box-shadow:0 10px 30px rgba(212,175,55,.4);
}

.black-btn{
    border:2px solid #d4af37;
    color:#fff;
}

.black-btn:hover{
    background:#d4af37;
    color:#000;
}

section{
    padding:80px 8%;
}

section h2{
    text-align:center;
    color:#ffba08;
    font-size:40px;
}

.line{
    width:90px;
    height:4px;
    background:#ffba08;
    margin:15px auto 50px;
    border-radius:30px;
}

/* Featured Cars */

.cars{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(320px,1fr));
    gap:35px;
}

.car-card{
    background: #13308A;
    border-radius:18px;
    overflow:hidden;
    transition:.4s;
    box-shadow:0 10px 25px rgba(0,0,0,.4);
}

.car-card:hover{
    transform:translateY(-10px);
    box-shadow:0 20px 40px rgba(212,175,55,.25);
}

.car-card img{
    width:100%;
    height:230px;
    object-fit:cover;
}

.car-card h3{
    padding:20px 20px 8px;
}

.price{
    color:#ffba08;
    font-size:28px;
    font-weight:bold;
    padding:0 20px;
}

.car-card p{
    padding:4px 20px;
    color:#d9d9d9;
}

.details-btn{
    display:block;
    margin:20px;
    text-align:center;
    text-decoration:none;
    background:#ffba08;
    color:#000;
    padding:14px;
    border-radius:30px;
    font-weight:bold;
    transition:.3s;
}

.details-btn:hover{
    background:#fff;
}
/* ===========================
   WHY CHOOSE US
=========================== */

.why{
    background:#0A2472;
}

.why-box{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:25px;
    max-width:1000px;
    margin:0 auto;
}

.why-box div{
    background:#13308A;
    border-left:4px solid #d4af37;
    border-radius:12px;
    padding:30px;
    min-height:120px;
    display:flex;
    justify-content:center;
    align-items:center;
    text-align:center;
    font-weight:500;
    transition:.3s;
}

.why-box div:hover{
    transform:translateY(-6px);
    box-shadow:0 10px 30px rgba(212,175,55,.25);
}

/* Center the last box */
.why-box div:last-child{
    grid-column:2;
}

/* ===========================
   CONTACT
=========================== */

.contact form{
    max-width:700px;
    margin:auto;
}

.contact input,
.contact textarea{
    width:100%;
    padding:18px;
    margin-bottom:20px;
    background:#13308A;
    border:none;
    border-radius:10px;
    color:#fff;
    font-size:16px;
}

.contact textarea{
    height:180px;
    resize:none;
}

.contact button{
    width:100%;
    padding:18px;
    border:none;
    border-radius:10px;
    background:#d4af37;
    color:#000;
    font-size:18px;
    font-weight:bold;
    cursor:pointer;
    transition:.3s;
}

.contact button:hover{
    background:#fff;
}

/* ===========================
   LOCATION
=========================== */

.location-box{
    max-width:800px;
    margin:auto;
    background:#181818;
    padding:40px;
    border-radius:15px;
    text-align:center;
    box-shadow:0 10px 30px rgba(31, 31, 31, 0.3);
}

.location-box h3{
    color:#d4af37;
    margin-bottom:20px;
}

.location-box p{
    margin:10px 0;
    color:#ddd;
}

.map{
    margin-top:30px;
    border-radius:15px;
    overflow:hidden;
}

/* ===========================
   FOOTER
=========================== */

footer{
    background:#081c5a;
    text-align:center;
    padding:35px;
    color:#aaa;
}

footer p{
    margin:8px 0;
}

/* ===========================
   RESPONSIVE
=========================== */

@media(max-width:900px){

header{
    flex-direction:column;
    gap:20px;
}

nav ul{
    flex-wrap:wrap;
    justify-content:center;
    gap:15px;
}

.overlay h2{
    font-size:40px;
}

.overlay p{
    font-size:18px;
}

.why-box{
    grid-template-columns:repeat(2,1fr);
}

.why-box div:last-child{
    grid-column:1 / 3;
    justify-self:center;
    width:80%;
}

}

@media(max-width:600px){

.logo{
    flex-direction:column;
    text-align:center;
}

.logo h1{
    font-size:24px;
}

.overlay h2{
    font-size:32px;
}

.overlay p{
    font-size:16px;
}

.buttons{
    flex-direction:column;
    width:100%;
    align-items:center;
}

.gold-btn,
.black-btn{
    width:250px;
    text-align:center;
}

.cars{
    grid-template-columns:1fr;
}

.why-box{
    grid-template-columns:1fr;
}

.why-box div:last-child{
    grid-column:auto;
    width:100%;
}

section{
    padding:60px 5%;
}

}
/* ===========================
   VEHICLES PAGE
=========================== */

.page-title{
    background:#13308A;
    text-align:center;
    padding:70px 20px;
}

.page-title h1{
    font-size:48px;
    color:#FFBA08;
    margin-bottom:10px;
}

.page-title p{
    color:white;
    font-size:18px;
}

.search-section{
    display:flex;
    justify-content:center;
    align-items:center;
    flex-wrap:wrap;
    gap:15px;
    padding:40px 8%;
    background:#0A2472;
}

.search-section input,
.search-section select{
    padding:15px;
    width:250px;
    border:none;
    border-radius:8px;
    font-size:16px;
    outline:none;
}

.search-section button{
    padding:15px 30px;
    background:#FFBA08;
    color:#0A2472;
    border:none;
    border-radius:8px;
    font-weight:bold;
    cursor:pointer;
    transition:.3s;
}

.search-section button:hover{
    background:white;
}

.active{
    color:#FFBA08 !important;
    border-bottom:3px solid #FFBA08;
    padding-bottom:5px;
}
/* Vehicle Details Page */

.vehicle-details{
    display:flex;
    gap:50px;
    padding:60px 8%;
    flex-wrap:wrap;
}

.vehicle-gallery{
    flex:1;
    min-width:350px;
}

.main-image{
    width:100%;
    border-radius:15px;
    margin-bottom:20px;
}

.thumbnails{
    display:flex;
    gap:15px;
    flex-wrap:wrap;
}

.thumbnails img{
    width:120px;
    height:90px;
    object-fit:cover;
    border-radius:10px;
    cursor:pointer;
    border:3px solid transparent;
    transition:.3s;
}

.thumbnails img:hover{
    border-color:#FFBA08;
}

.vehicle-info{
    flex:1;
    min-width:350px;
}

.vehicle-info h1{
    color:#FFBA08;
    font-size:42px;
}

.vehicle-info h2{
    font-size:38px;
    margin:20px 0;
}

.vehicle-info table{
    width:100%;
    border-collapse:collapse;
    margin:25px 0;
}

.vehicle-info td{
    padding:14px;
    border-bottom:1px solid rgba(255,255,255,.2);
}

.vehicle-info p{
    margin-bottom:30px;
    line-height:1.8;
}
.slider{
    position:relative;
    width: 100%;
}

.main-image{
    width: 100%;
    display: block;
    border-radius: 15px;
}
.prev,
.next{
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    width: 55px;
    height: 55px;
    border: none;
    border-radius: 50%;
    background: #FFBA08;
    color: #0A2472;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    z-index: 100;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: 0.3s;
}

.prev{
    left:15px;
}

.next{
    right:15px;
}

.prev:hover,
.next:hover{
    background:white;
}

.thumbnails{
    display:flex;
    gap:10px;
    margin-top:20px;
    flex-wrap:wrap;
}

.thumbnails img{
    width:100px;
    height:75px;
    object-fit:cover;
    border-radius:8px;
    cursor:pointer;
    border:3px solid transparent;
    transition:.3s;
}

.thumbnails img:hover{
    border-color:#FFBA08;
}
/* ===========================
   BMW VEHICLE DETAILS PAGE
=========================== */

.vehicle-details{
    display:flex;
    gap:50px;
    padding:60px 8%;
    flex-wrap:wrap;
    align-items:flex-start;
}

.vehicle-gallery{
    flex:1;
    min-width:450px;
}

.slider{
    position:relative;
}

.main-image{
    width:100%;
    height:500px;
    object-fit:cover;
    border-radius:15px;
    box-shadow:0 10px 30px rgba(0,0,0,.35);
}

.prev,
.next{
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    width:55px;
    height:55px;
    border:none;
    border-radius:50%;
    background:#FFBA08;
    color:#0A2472;
    font-size:30px;
    font-weight:bold;
    cursor:pointer;
    transition:.3s;
}

.prev{
    left:20px;
}

.next{
    right:20px;
}

.prev:hover,
.next:hover{
    background:#fff;
}

.thumbnails{
    display:flex;
    gap:12px;
    margin-top:20px;
    flex-wrap:wrap;
}

.thumbnails img{
    width:110px;
    height:80px;
    object-fit:cover;
    border-radius:10px;
    cursor:pointer;
    border:3px solid transparent;
    transition:.3s;
}

.thumbnails img:hover{
    border-color:#FFBA08;
    transform:scale(1.05);
}

.vehicle-info{
    flex:1;
    min-width:350px;
}

.vehicle-info h1{
    color:#FFBA08;
    font-size:42px;
    margin-bottom:10px;
}

.vehicle-info .price{
    font-size:40px;
    color:#fff;
    margin-bottom:25px;
}

.badges{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
    margin-bottom:25px;
}

.badges span{
    background:#FFBA08;
    color:#0A2472;
    padding:10px 18px;
    border-radius:30px;
    font-weight:600;
}

.specs{
    width:100%;
    border-collapse:collapse;
    margin:30px 0;
}

.specs td{
    padding:14px;
    border-bottom:1px solid rgba(255,255,255,.15);
}

.specs tr:hover{
    background:rgba(255,255,255,.05);
}

.vehicle-info h3{
    color:#FFBA08;
    margin-bottom:15px;
}

.vehicle-info p{
    line-height:1.8;
    color:#ddd;
}

.vehicle-features{
    background:#13308A;
}

.features-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
    gap:20px;
    margin-top:40px;
}

.features-grid div{
    background:#0A2472;
    padding:20px;
    border-radius:10px;
    border-left:4px solid #FFBA08;
}

.finance-box{
    max-width:700px;
    margin:auto;
    background:#13308A;
    text-align:center;
    padding:40px;
    border-radius:15px;
}

.finance-box h1{
    color:#FFBA08;
    font-size:42px;
    margin:20px 0;
}

.finance-box p{
    color:#ddd;
    margin-bottom:25px;
}

@media(max-width:900px){

.vehicle-details{
    flex-direction:column;
}

.main-image{
    height:320px;
}

.vehicle-gallery,
.vehicle-info{
    min-width:100%;
}

.thumbnails{
    justify-content:center;
}

.prev,
.next{
    width:45px;
    height:45px;
}

}
.location{
    display:flex;
    flex-direction:column;
    gap:40px;
}

.map{
    width:100%;
    border-radius:15px;
    overflow:hidden;
    box-shadow:0 10px 30px rgba(0,0,0,.35);
}

.map iframe{
    width:100%;
    height:550px;
    display:block;
    border:0;
}
