/* ------------------------------
   PAGE PRODUIT
------------------------------ */

.product_page {
    max-width: 1000px;
    margin: 40px auto;
    padding: 20px;
    font-family: "Segoe UI", Roboto, Arial, sans-serif;
    color: #333;
}

.back_btn {
    display: inline-block;
    margin-bottom: 25px;
    text-decoration: none;
    color: #777;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    transition: 0.2s;
}

.back_btn:hover {
    color: #000;
}

/* ------------------------------
   LAYOUT
------------------------------ */

.product_wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    align-items: start;
}

/* ------------------------------
   IMAGES
------------------------------ */

.product_images {
    max-width: 100%;
    position: relative;
}

.image_slider {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main_image {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
    border-radius: 10px;
    background: #f3f3f3;
    padding: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.nav_btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.55);
    color: white;
    border: none;
    font-size: 20px;
    padding: 6px 10px;
    cursor: pointer;
    border-radius: 4px;
    z-index: 2;
}

.prev_btn {
    left: 10px;
}

.next_btn {
    right: 10px;
}

.dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
}

.dot {
    width: 8px;
    height: 8px;
    background: #ccc;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.dot.active {
    background: #2c7a2c;
    transform: scale(1.1);
}

/* ------------------------------
   INFO PRODUIT (STYLE CARTE)
------------------------------ */

.product_info {
    background: #fafafa;
    border-radius: 10px;
    padding: 20px 22px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product_info h1 {
    font-size: 24px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
    color: #222;
}

.product_price {
    font-size: 26px;
    font-weight: 700;
    color: #1f7a3a;
    margin: 0;
}

.product_meta {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #888;
}

.product_description {
    font-size: 15px;
    line-height: 1.7;
    color: #555;
    white-space: pre-line;
    border-top: 1px solid #e3e3e3;
    padding-top: 12px;
}

.stock_info {
    font-size: 14px;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.stock_info strong {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 999px;
    background: #e6f4ea;
    color: #1f7a3a;
    font-size: 13px;
}

/* ------------------------------
   FLASH / LOGIN / BOUTON
------------------------------ */

.flash_message {
    background: #f6f6f6;
    border-left: 4px solid #2c7a2c;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    color: #333;
}

.login_notice {
    font-size: 14px;
    color: #b33;
    font-weight: 500;
}

.btn_add {
    background-color: #2c7a2c;
    color: white;
    padding: 11px 22px;
    border: none;
    border-radius: 999px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    align-self: flex-start;
    margin-top: 4px;
}

.btn_add:hover {
    background-color: #256325;
    transform: translateY(-1px);
}

.btn_add:disabled {
    background-color: #aaa;
    cursor: not-allowed;
    transform: none;
}

/* ------------------------------
   RESPONSIVE
------------------------------ */

@media (max-width: 800px) {
    .product_wrapper {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .main_image {
        max-height: 320px;
    }
}

@media (max-width: 500px) {
    .product_page {
        padding: 12px;
    }

    .main_image {
        max-height: 260px;
    }

    .product_info {
        padding: 16px 14px;
    }

    .product_info h1 {
        font-size: 20px;
    }

    .product_price {
        font-size: 20px;
    }
}
