/* 
   Variables Globales
    */
:root {
    --primary-color: #1b3022; /* Vert Forêt profond */
    --accent-color: #8c704b;  /* Bronze terreux */
    --bg-cream: #fdfaf5;      /* Crème doux */
    --font-main: 'Montserrat', sans-serif;
    --font-heading: 'Playfair Display', serif;
}

/* 
   Styles Globaux du Body
    */
body {
    font-family: var(--font-main);
    color: var(--primary-color);
    background-color: var(--bg-cream);
    overflow-x: hidden;
    /*padding-top: 160px;*/
}

h1, h2, h3 { font-family: var(--font-heading); }

/* 
   Header / Navbar
    */
.fixed-top {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1030;
    background-color: var(--bg-cream);
}

main {
    /* Ajustement pour laisser la place au header */
    padding-top: 0;
}

.top-container{
    padding-top: 150px;
}
@media (max-width: 991px) {
    body { padding-top: 140px; }
}

/* Announcement Bar */
.announcement-bar {
    background-color: var(--primary-color);
    color: #e0e0e0;
    font-size: 0.8rem;
    padding: 10px 0;
    font-weight: 400;
    letter-spacing: 1px;
}

/* Navbar Custom */
.navbar {
    transition: all 0.4s ease;
    padding: 25px 0;
}
.navbar.scrolled {
    background: rgba(253, 250, 245, 0.98);
    backdrop-filter: blur(10px);
    padding: 12px 0;
    box-shadow: 0 4px 20px rgba(27, 48, 34, 0.08);
}
.nav-link {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1.5px;
    color: var(--primary-color) !important;
    margin: 0 12px;
}

/* 
   Hero Section
    */
.hero {
    height: 85vh;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)),
    url('https://images.unsplash.com/photo-1542838132-92c53300491e?auto=format&fit=crop&w=1600&q=80');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    margin-bottom: 1rem;
}

/* 
   v-lstProduit (Liste des Produits)
    */
.hover-link { transition: color 0.3s ease; }
.hover-link:hover { color: var(--accent-color) !important; }

.product-card {
    background-color: #fff;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05) !important;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "•";
    color: #dee2e6;
}

/* Bouton Ajouter */
.btn-add-cart {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* 
   v-unProduit (Fiche Produit)
    */
.nav-tabs .nav-link { color: var(--primary-color); }
.nav-tabs .nav-link.active {
    background-color: white !important;
    color: var(--accent-color);
    border-bottom: 3px solid var(--accent-color) !important;
}

.main-image-wrapper img {
    transition: transform 0.5s ease;
}
.main-image-wrapper:hover img {
    transform: scale(1.02);
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: none;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
}
.btn-primary:hover {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

#mainProductImage {
    width: 80%;       /* ou une valeur fixe : width: 400px; */
    height: auto;     /* conserve les proportions */
    display: block;
    margin: 0 auto;   /* centre l'image */
}

/* 
   v-panier (Panier)
    */
.fs-7 { font-size: 0.75rem; }

.btn-terra {
    background-color: #1b3022; /* Vert forêt TERRA */
    color: white;
    border: none;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}
.btn-terra:hover {
    background-color: #8c704b; /* Marron bronze TERRA */
    color: white;
    transform: translateY(-2px);
}

.btn-outline-secondary:hover {
    background-color: #1b3022;
    border-color: #1b3022;
}

.table > :not(caption) > * > * {
    padding: 1rem 0.5rem;
}

/* 
   Product Cards Globaux (head)
    */
.product-card {
    border: none;
    transition: all 0.4s ease;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.02);
}
.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
}

.product-img-wrapper {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1/1;
}

/* 
   Utility Classes - Text & Spacing
    */

/* Letter Spacing Utilities */
.letter-spacing-xl { letter-spacing: 3px; }
.letter-spacing-lg { letter-spacing: 2px; }
.letter-spacing-md { letter-spacing: 1.5px; }
.letter-spacing-sm { letter-spacing: 1px; }

/* Font Size Utilities */
.fs-80 { font-size: 0.8rem; }
.fs-75 { font-size: 0.75rem; }
.fs-70 { font-size: 0.7rem; }
.fs-65 { font-size: 0.65rem; }

/* Color Utilities */
.text-primary-dark { color: var(--primary-color); }
.text-accent { color: var(--accent-color); }
.text-success-light { color: #8cffb3; }

/* 
   Accent Text / Special Styling
   */

/* Hero Section - Accent Text */
.hero-accent {
    letter-spacing: 3px;
    color: #8cffb3;
}

/* Category / Small Uppercase Text */
.category-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--primary-color);
    font-weight: 600;
}

.category-label-md {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--primary-color);
    font-weight: 600;
}

/* 
   Dividers & Separators
   */

.divider-accent {
    width: 50px;
    height: 2px;
    background-color: var(--primary-color);
    margin: 1rem auto;
}

/* 
   Images
   */

/* Product Grid Image */
.product-grid-img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

/* Thumbnail Image */
.img-thumbnail-sm {
    width: 70px;
    height: 70px;
    object-fit: contain;
}

/* 
   Forms & Inputs
   */

/* Quantity Input */
.input-qty {
    max-width: 60px;
}

/* 
   Positioning & Sticky Elements
   */

/* Sticky Sidebar / Section */
.sticky-section {
    top: 130px;
    z-index: 10;
}

/* Badge/Badge Positioning */
.badge-overlay {
    z-index: 2;
}

/* 
   Page Section Padding (v-paiement, v-commande)
   */

/* Page top padding */
.page-top-padding {
    padding-top: 150px;
}

/* 
   Headings & Typography
   */

/* Panier Title Style */
.panier-title {
    font-family: var(--font-heading);
    color: var(--primary-color);
}

/* Heading Level 5 - Dashboard Style */
.heading-section {
    color: var(--primary-color);
}

/* 
   Alerts & Warnings
   */

/* Shipping Info Alert */
.alert-shipping-info {
    font-size: 0.8rem;
}

/* 
   Payment Pages Styling (from v-paiement.php)
   */

/* Payment Page Body */
.payment-page-body {
    font-family: Arial, sans-serif;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

/* Payment Container */
.payment-container {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

/* Payment Container Heading */
.payment-container h1 {
    color: #333;
    margin-bottom: 10px;
}

/* Payment Container Paragraph */
.payment-container p {
    color: #666;
    margin: 10px 0;
}

/* Loading Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Payment Button */
.btn-payment {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    margin-top: 20px;
    transition: background 0.3s ease;
}

.btn-payment:hover {
    background: #2980b9;
}

/* Small Payment Info */
.payment-info-small {
    font-size: 12px;
    color: #999;
}

/* 
   Checkout Form Styling
   */

/* Step Number Badge */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    font-weight: bold;
    font-size: 0.9rem;
}

/* Payment Card Selection */
.payment-card {
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.payment-card:hover {
    background-color: #f8f9fa !important;
}

/* 
   Status Pages (v-paiement-ok, ko, refuse)
   */

/* Status Container Top Padding */
.top-container {
    padding-top: 150px;
}

/* 
   Mini Cart / Order Summary
   */

/* Mini Cart List */
.mini-cart-list {
    max-height: 400px;
    overflow-y: auto;
}

/* 
   Table & Cart Items
   */

/* Product Row Min Width */
.product-row-img-col {
    min-width: 250px;
}

/* 
   Navigation Tabs (Product Page)
   */

/* Tab Button Letter Spacing */
.tab-button-spaced {
    letter-spacing: 1px;
}

/* 
   Search Results (Dynamic Content)
   */

.search-result-item {
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
}

.search-result-item:hover {
    background: #f8f9fa;
}

.search-result-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 4px;
}

.search-result-name {
    font-size: 0.875rem;
    font-weight: 600;
}

.search-result-price {
    font-size: 0.75rem;
    color: #888;
}

.search-result-view-all {
    padding: 10px 14px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
}

.search-result-empty {
    padding: 10px 14px;
    font-size: 0.875rem;
    color: #888;
}

/* 
   Autocomplete Results (Dynamic Content)
*/

.autocomplete-suggestions {
    position: absolute;
    z-index: 9999;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    list-style: none;
    margin: 0;
    padding: 4px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    max-height: 250px;
    overflow-y: auto;
}

.autocomplete-item {
    padding: 10px 14px;
    cursor: pointer;
    font-size: 0.875rem;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
}

.autocomplete-item:hover {
    background: #f8f9fa;
}

/*
   Search Input States
  */

.search-input-hidden {
    width: 0;
    opacity: 0;
    padding: 0;
    transition: all 0.3s ease;
}

.search-results-container {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    z-index: 9999;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    list-style: none;
    margin: 0;
    padding: 4px 0;
    width: 300px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    max-height: 350px;
    overflow-y: auto;
}

/* Search Button Styling */
button.nav-link {
    cursor: pointer;
    pointer-events: auto;
    background: none;
    border: none;
    padding: inherit;
    text-decoration: none;
}

/*
   Font Size Utilities (Additional)
  */

.fs-60 { font-size: 0.6rem; }

/*
   Size & Dimension Utilities
  */

/* Fixed Size Containers */
.size-70 {
    width: 70px;
    height: 70px;
}

.size-140 {
    width: 140px;
}

/* Progress Bar Heights */
.progress-height-sm {
    height: 8px;
}

.progress-height-md {
    height: 10px;
}

/*
   Image Utilities
  */

/* Full Container Image Fill */
.img-fill {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-img-wrapper img {
    transition: transform 0.8s ease;
    object-fit: cover;
    width: 100%;
    height: 100%;
}

.product-card:hover img {
    transform: scale(1.1);
}

.btn-add-cart {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: 0.3s;
}
.btn-add-cart:hover {
    background: var(--accent-color);
}

/*
   Badge Bio
   */
.badge-bio {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(40, 167, 69, 0.9);
    color: white;
    padding: 5px 12px;
    font-size: 0.65rem;
    font-weight: bold;
    text-transform: uppercase;
    z-index: 2;
}

/*
   Footer
 */
footer {
    background-color: var(--primary-color);
    color: #b0b0b0;
    padding: 80px 0 30px;
}
footer h5 {
    color: var(--accent-color);
    margin-bottom: 25px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}
footer a {
    color: #d0d0d0;
    text-decoration: none;
    transition: 0.3s;
    font-size: 0.9rem;
}
footer a:hover {
    color: var(--accent-color);
}