@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --main-color: #C5A55A;
    --text-color: #3D3527;
    --bg-color:   #fff;
}

* {
    font-family: 'Poppins', sans-serif;
    scroll-behavior: smooth;
    box-sizing: border-box;
}

html::-webkit-scrollbar       { width: 0.5rem; background: transparent; }
html::-webkit-scrollbar-thumb { border-radius: 5rem; background: var(--text-color); }

body  { color: var(--text-color); }
img   { max-width: 100%; }

section { padding: 4rem 0 2rem; }

/* override Bootstrap container to keep original max-width */
.container, .container-xl { max-width: 1068px; }

/* ── Navbar ──────────────────────────────────────── */
#mainNav {
    background: transparent;
    transition: background .4s ease, box-shadow .4s ease;
    padding: 12px 0;
}
#mainNav.shadow-nav {
    background: var(--bg-color);
    box-shadow: 0 4px 20px rgba(15,54,55,.1);
}

#mainNav .nav-link {
    color: var(--text-color) !important;
    font-size: .95rem;
    text-transform: uppercase;
    font-weight: 500;
    padding: .3rem .8rem;
    border-bottom: 3px solid transparent;
}
#mainNav .nav-link:hover,
#mainNav .nav-link.active {
    color: var(--main-color) !important;
    border-bottom-color: var(--main-color);
}

/* custom hamburger icon color */
#mainNav .navbar-toggler { border-color: var(--text-color); }
#mainNav .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%233D3527' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* search icon */
.search-icon {
    font-size: 1.4rem;
    cursor: pointer;
    color: var(--bg-color);
}
#mainNav.shadow-nav .search-icon { color: var(--text-color); }

.search-box {
    position: absolute;
    top: 110%;
    right: 0;
    width: 300px;
    background: var(--bg-color);
    box-shadow: 4px 4px 20px rgba(15,54,55,.1);
    border: 1px solid var(--main-color);
    border-radius: .5rem;
    clip-path: circle(0% at 100% 0%);
    z-index: 200;
}
.search-box.active {
    clip-path: circle(144% at 100% 0%);
    transition: .4s;
}
.search-box input {
    width: 100%;
    padding: 15px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
}

/* ── Buttons ─────────────────────────────────────── */
.btn {
    background: var(--main-color) !important;
    color: #fff !important;
    border: none !important;
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
}
.btn:hover, .btn:focus {
    background: #B08F45 !important;
    color: #fff !important;
}

/* ── Section headings ────────────────────────────── */
.heading        { text-align: center; }
.heading span   { font-weight: 500; color: var(--main-color); }
.heading p      { font-size: 1rem; font-weight: 300; }

.top{
	
	margin-top: 10%;
}
/* ── Hero (home) section ─────────────────────────── */
.home {
    max-width: 1900px;
    margin: auto;
    width: 100%;
    min-height: 940px;
    display: flex;
    align-items: center;
    background: url(../img/Background-home.png) no-repeat center left / cover;
    position: relative;
}
.home::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(61,53,39,.08) 0%, rgba(197,165,90,.35) 100%);
    mix-blend-mode: color;
    pointer-events: none;
    z-index: 1;
}
.home > * { position: relative; z-index: 2; }

.home-text             { padding-left: 130px; }
.home-text h1          { font-size: 2.4rem; }
.home-text span        { color: var(--main-color); }
.home-text p           { font-size: 1.338rem; font-weight: 300; margin: .5rem 0 1.2rem; }

/* ── Car boxes (home & cars page) ───────────────── */
.car-box {
    position: relative;
    height: 200px;
    border-radius: .5rem;
    overflow: hidden;
}
.car-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s;
}
.car-box:hover img { transform: scale(1.1); }
.car-box h2 {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    font-weight: 400;
    font-size: 1rem;
    background: var(--bg-color);
    padding: 8px;
    border-radius: .5rem;
    margin: 0;
}
.car-box:hover h2 {
    background: var(--main-color);
    color: #fff;
}

/* ── About section ──────────────────────────────── */
.about-text span { font-weight: 500; color: var(--main-color); }
.about-text h2   { font-size: 1.7rem; }
.about-text p    { font-size: .938rem; margin: .5rem 0 1.4rem; }

/* ── Parts boxes ────────────────────────────────── */
.part-box {
    background: #f6f6f6;
    border-radius: .5rem;
    padding: 20px;
    display: flex;
    flex-direction: column;
    position: relative;
    height: 100%;
}
.part-box img {
    width: 100%;
    height: 150px;
    object-fit: contain;
    object-position: center;
    margin-bottom: 1rem;
}
.part-box h3    { font-size: 1.1rem; font-weight: 600; }
.part-box .price {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--main-color);
}
.part-box .bx   { color: var(--main-color); margin: .8rem 0; display: block; }
.part-box .btn  { max-width: 120px; }
.part-box .details {
    display: flex;
    align-items: center;
    position: absolute;
    bottom: 1.8rem;
    right: 1rem;
    font-size: 1rem;
    color: var(--text-color);
    text-decoration: none;
}
.part-box .details:hover { color: var(--main-color); text-decoration: underline; }

/* ── Blog boxes ─────────────────────────────────── */
.blog-box         { padding: 20px; transition: background .2s; }
.blog-box:hover   { background: #f6f6f6; }
.blog-box span    { font-size: .8rem; color: var(--main-color); }
.blog-box h3      { font-size: 1.2rem; }
.blog-box p       { font-size: .933rem; margin: 4px 0; }

.blog-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-color);
    text-decoration: none;
}
.blog-btn .bx  { font-size: 20px; }
.blog-btn:hover {
    color: var(--main-color);
    gap: .7rem;
    transition: .4s;
}

/* ── Page hero (inner pages) ─────────────────────── */
.page-hero {
    padding: 8rem 0 3rem;
    text-align: center;
    background: #f9f9f9;
}
.page-hero span { font-weight: 500; color: var(--main-color); }
.page-hero h1   { font-size: 2rem; margin: .3rem 0 .5rem; }
.page-hero p    { font-size: .95rem; font-weight: 300; color: #666; }

/* ── Filters bar ─────────────────────────────────── */
.filters {
    background: #fff;
    border-bottom: 1px solid #eee;
    padding: 1rem 0;
    position: sticky;
    top: 68px;
    z-index: 90;
}
.filters form { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }
.filters input,
.filters select {
    padding: .5rem .9rem;
    border: 1px solid #ddd;
    border-radius: .4rem;
    font-family: 'Poppins', sans-serif;
    font-size: .9rem;
    color: var(--text-color);
    background: #fff;
}
.filters input:focus,
.filters select:focus { outline: none; border-color: var(--main-color); }
.filters .reset       { color: #888; font-size: .85rem; text-decoration: none; }
.filters .reset:hover { color: var(--main-color); }

/* ── Cars catalogue (cars.php) ──────────────────── */
.car-card {
    border-radius: .5rem;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
    transition: .3s;
    height: 100%;
}
.car-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,.12); transform: translateY(-3px); }
.car-card .card-img { position: relative; height: 200px; overflow: hidden; }
.car-card .card-img img { width: 100%; height: 100%; object-fit: cover; transition: .5s; }
.car-card:hover .card-img img { transform: scale(1.07); }
.car-card .badge-status {
    position: absolute; top: .7rem; right: .7rem;
    background: var(--main-color); color: #fff;
    font-size: .72rem; padding: .2rem .6rem; border-radius: 2rem;
}
.car-card .badge-status.vendu   { background: #555; }
.car-card .badge-status.reserve { background: #e67e22; }
.car-card .card-body     { padding: 1rem; }
.car-card .card-body h3  { font-size: 1.05rem; font-weight: 600; }
.car-card .card-body .price { color: var(--main-color); font-weight: 700; font-size: 1.1rem; margin: .3rem 0; }
.car-card .card-body .meta  { font-size: .82rem; color: #888; display: flex; gap: .8rem; flex-wrap: wrap; margin: .4rem 0 .8rem; }

.no-results { text-align: center; padding: 4rem 1rem; color: #888; }
.no-results i { font-size: 3rem; color: #ddd; display: block; margin-bottom: 1rem; }

/* ── Reservation form ────────────────────────────── */
.resa-form label              { font-size: .85rem; color: #555; font-weight: 500; }
.resa-form .form-control,
.resa-form .form-select {
    font-family: 'Poppins', sans-serif;
    font-size: .95rem;
    color: var(--text-color);
    border-color: #ddd;
}
.resa-form .form-control:focus,
.resa-form .form-select:focus {
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(197,165,90,.15);
}
.alert-ok  { background: rgba(40,167,69,.08);  border: 1px solid rgba(40,167,69,.3);  color: #1d7a35; padding: 1rem; border-radius: .5rem; margin-bottom: 1.5rem; }
.alert-err { background: rgba(217,4,41,.08);   border: 1px solid rgba(217,4,41,.3);   color: #b00020; padding: 1rem; border-radius: .5rem; margin-bottom: 1.5rem; }
.info-box  { background: #f9f9f9; border-radius: .5rem; padding: 1.5rem; }
.info-box h4 { font-size: 1rem; margin-bottom: 1rem; }
.info-item   { display: flex; align-items: flex-start; gap: .7rem; margin-bottom: 1rem; font-size: .9rem; }
.info-item .bx { font-size: 1.3rem; color: var(--main-color); margin-top: .1rem; }

/* ── Blog article ────────────────────────────────── */
.article-hero    { padding: 8rem 0 3rem; text-align: center; background: #f9f9f9; }
.article-hero h1 { font-size: 2rem; max-width: 700px; margin: .4rem auto; }
.article-hero .meta { color: #888; font-size: .85rem; margin-top: .5rem; }
.article-body    { max-width: 760px; margin: 0 auto; padding: 3rem 1rem 5rem; }
.article-body .cover { width: 100%; border-radius: .6rem; margin-bottom: 2rem; }
.article-body h2 { font-size: 1.4rem; margin: 1.5rem 0 .5rem; }
.article-body p  { line-height: 1.85; margin-bottom: 1rem; color: #333; }
.article-body ul, .article-body ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.article-body li { margin-bottom: .4rem; line-height: 1.7; }
.article-body blockquote { border-left: 3px solid var(--main-color); padding-left: 1.2rem; color: #666; margin: 1.5rem 0; font-style: italic; }
.article-body figure img { width: 100%; border-radius: .4rem; }
.article-body figcaption { text-align: center; font-size: .8rem; color: #888; margin-top: .4rem; }
.back-btn { display: inline-flex; align-items: center; gap: .4rem; color: #888; margin-bottom: 2rem; font-size: .9rem; text-decoration: none; }
.back-btn:hover { color: var(--main-color); }

/* ── Footer ──────────────────────────────────────── */
.footer {
    background: var(--text-color);
    color: #f6f6f6;
    border-top: 2px solid var(--main-color);
    padding: 3rem 0;
}
.footer .logo      { display: block; margin-bottom: 1rem; }
.social a          { font-size: 24px; color: var(--bg-color); margin-right: 1rem; text-decoration: none; }
.social a:hover    { color: var(--main-color); }
.footer-col h3     { font-size: 1.1rem; font-weight: 400; margin-bottom: 1rem; }
.footer-col a,
.footer-col p      { color: #818181; margin-bottom: 10px; display: block; text-decoration: none; }
.footer-col a:hover { color: var(--bg-color); }
.copyright {
    padding: 20px;
    text-align: center;
    color: var(--bg-color);
    background: var(--text-color);
    font-size: .9rem;
}

/* ── Modals légaux ───────────────────────────────── */
.legal-modal {
    background: var(--text-color);
    color: #f0ebe0;
    border: 1px solid var(--main-color);
    border-radius: 8px;
}
.legal-modal .modal-header {
    border-bottom: 1px solid var(--main-color);
    padding: 1.1rem 1.5rem;
}
.legal-modal .modal-title {
    color: var(--main-color);
    font-weight: 500;
    font-size: 1.1rem;
}
.legal-modal .modal-body {
    padding: 1.5rem;
    max-height: 60vh;
}
.legal-modal .modal-body h6 {
    color: var(--main-color);
    font-weight: 500;
    margin-top: 1.2rem;
    margin-bottom: .4rem;
}
.legal-modal .modal-body p {
    color: #b0a898;
    font-size: .9rem;
    line-height: 1.7;
}
.legal-modal .modal-footer {
    border-top: 1px solid rgba(197,165,90,.3);
    padding: .8rem 1.5rem;
}

/* ── Responsive ──────────────────────────────────── */
@media (max-width: 991px) {
    section { padding: 3rem 0 1rem; }
    .home-text { padding-left: 2rem; }
    .home-text h1 { font-size: 2.1rem; }
    /* mobile nav: active link becomes gold background */
    #mainNav .nav-link:hover,
    #mainNav .nav-link.active {
        background: var(--main-color);
        color: #fff !important;
        border-bottom: none;
    }
}
@media (max-width: 727px) {
    .heading span  { font-size: .9rem; }
    .heading h2    { font-size: 1.4rem; }
    .about-text    { text-align: center; }
    .about-text h2 { font-size: 1.4rem; }
}
@media (max-width: 360px) {
    .home          { min-height: 500px; }
    .home-text h1  { font-size: 2rem; }
}
