/* style.css — ATS Occasion */

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

:root {
    --blue:       #2F358C;
    --blue-dark:  #252b75;
    --text:       #111111;
    --text-light: #6B7280;
    --border:     #E5E7EB;
    --bg:         #FFFFFF;
    --bg-soft:    #F9FAFB;
}

* { box-sizing: border-box; }

body {
    font-family: "Inter", sans-serif;
    font-size: 15px;
    margin: 0;
    background: var(--bg);
    color: var(--text);
    scroll-behavior: smooth;
}

/* ── HEADER ── */
header {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;

}

.header-content {
    max-width: 1200px;
    margin: auto;
    padding: 0 20px;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-block {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--blue);
    gap: 12px;
}

.brand-block:hover { opacity: 0.85; }

.brand-logo { height: 36px; width: auto; }

.brand-text {
    font-family: "Inter", sans-serif;
    font-weight: 600;
    font-size: 18px;
    color: var(--blue);
    white-space: nowrap;
    z-index: 2;
    line-height: 1;
}

.btn-site {
    text-decoration: none;
    color: var(--blue);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    z-index: 2;
}

.btn-site:hover { text-decoration: underline; }

/* ── HERO BAND ── */
.hero {
    background: var(--blue);
    color: #fff;
    padding: 12px 0;
    text-align: center;
}

.hero h1 {
    margin: 0;
    font-size: 15px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-block;
    vertical-align: middle;
}

.info-link {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.4);
    color: #fff;
    padding: 3px 12px;
    border-radius: 20px;
    cursor: pointer;
    margin-left: 14px;
    font-size: 13px;
    vertical-align: middle;
    font-family: "Inter", sans-serif;
}

.info-link:hover { background: rgba(255,255,255,0.28); }

/* ── GRID PRODUITS ── */
.container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

@media (max-width: 960px) {
    .container { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .container { grid-template-columns: 1fr; }
}

/* ── CARDS ── */
.product-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s, border-color 0.2s;
    scroll-margin-top: 80px;
}

.product-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    border-color: var(--blue);
}

.img-container {
    width: 100%;
    height: 180px;
    background: var(--bg-soft);
    position: relative;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    mix-blend-mode: multiply;
    cursor: zoom-in;
    transition: transform 0.2s ease;
}

.badge {
    position: absolute;
    top: 10px;
    left: 10px;
    color: #fff;
    background: var(--blue);
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    z-index: 2;
}

/* card body */
.product-card > div:not(.img-container):not(.bid-box):not(.closed-msg) {
    padding: 16px 18px 0;
}

.price-tag {
    color: var(--blue);
    font-size: 22px;
    font-weight: 600;
    transition: color 0.4s ease;
}

.flash { color: #D97706 !important; }

/* ── BID BOX ── */
.bid-box {
    background: var(--bg-soft);
    padding: 16px 18px;
    border-top: 1px solid var(--border);
    font-size: 14px;
    margin-top: auto;
}

.closed-msg {
    background: var(--bg-soft);
    color: var(--text-light);
    padding: 16px 18px;
    text-align: center;
    font-weight: 500;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

/* ── FORMULAIRE ── */
input {
    width: 100%;
    padding: 9px 12px;
    margin: 5px 0 10px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 15px;
    font-family: "Inter", sans-serif;
}

input:focus {
    border-color: var(--blue);
    outline: none;
    box-shadow: 0 0 0 3px rgba(47,53,140,0.12);
}

.btn-submit {
    background: var(--blue);
    color: #fff;
    border: none;
    padding: 10px 20px;
    width: 100%;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    font-family: "Inter", sans-serif;
    transition: background 0.2s;
}

.btn-submit:hover { background: var(--blue-dark); }
.btn-submit:disabled { background: #D1D5DB; cursor: not-allowed; }

.legal-note {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 8px;
    line-height: 1.4;
    text-align: center;
    display: block;
    font-style: italic;
}

/* ── FOOTER ── */
footer {
    background: var(--bg-soft);
    padding: 36px 20px;
    text-align: center;
    font-size: 14px;
    border-top: 1px solid var(--border);
    color: var(--text-light);
    line-height: 1.8;
}

footer a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
}

footer a:hover { color: var(--blue); }

/* ── MODAL INFO ── */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.45);
}

.modal-content {
    background: var(--bg);
    margin: 10% auto;
    padding: 28px;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.15);
    line-height: 1.6;
}

.modal-content h3 {
    color: var(--blue);
    margin-top: 0;
    border-bottom: 1px solid var(--border);
    padding-bottom: 10px;
    font-size: 18px;
}

.close-modal {
    float: right;
    font-size: 26px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-light);
    line-height: 1;
}

.close-modal:hover { color: var(--text); }

.modal-content ul { padding-left: 20px; }
.modal-content li { margin-bottom: 8px; }

/* ── TOAST ── */
#toast {
    visibility: hidden;
    position: fixed;
    top: 72px;
    left: 50%;
    transform: translateX(-50%);
    background: #1F2937;
    color: #fff;
    padding: 11px 24px;
    border-radius: 6px;
    z-index: 1000;
    font-size: 14px;
}

.show { visibility: visible !important; }

/* ── LIGHTBOX ── */
.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 3000;
    left: 0; top: 0;
    width: 100%; height: 100%;
    overflow: hidden;
    background: rgba(0,0,0,0.90);
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.25s;
}

.lightbox-content {
    margin: auto;
    display: block;
    max-width: 95%;
    max-height: 95vh;
    object-fit: contain;
    border-radius: 4px;
    animation: zoomIn 0.25s;
}

.lightbox-close {
    position: absolute;
    top: 18px;
    right: 26px;
    color: #F9FAFB;
    font-size: 36px;
    font-weight: 600;
    cursor: pointer;
    z-index: 3001;
    line-height: 1;
}

.lightbox-close:hover { color: #D1D5DB; }

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3em;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    user-select: none;
    padding: 20px;
    z-index: 100;
    transition: color 0.2s;
    font-weight: bold;
}

.lightbox-nav:hover { color: #fff; }

@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }
@keyframes zoomIn { from { transform: scale(0.92) } to { transform: scale(1) } }
