/* ========== VARIABLES ========== */
:root {
  --primary-color: #0077cc;
  --primary-dark: #005fa3;
  --danger-color: #e74c3c;
  --danger-dark: #c0392b;
  --bg-light: #f6f8fa;
  --text-dark: #2c3e50;
  --white: #ffffff;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --border-radius: 10px;
  --transition: all 0.3s ease;
}

/* ========== animation ========== */
body1 {
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: navajowhite;
}

.box {
	display: flex;
    border: 4px solid #ffffff;
}

.box .inner {
	width: 800px;
	height: 100px;
	line-height: 100px;
	font-size: 2em;
	font-family: sans-serif;
	font-weight: bold;
	white-space: nowrap;
	overflow: hidden;

}

.box .inner:first-child {
	background-color: rgb(14, 137, 185);
	color: hsl(300, 83%, 42%);
	transform-origin: right;
	transform: perspective(100px) rotateY(-8deg);
}

.box .inner:last-child {
	background-color: rgb(20, 81, 172);
	color: rgb(31, 182, 31);
	transform-origin: left;
	transform: perspective(100px) rotateY(8deg);
}

.box .inner span {
	position: absolute;
	animation: marquee 5s linear infinite;
}

.box .inner:first-child span {
	animation-delay: 2.5s;
	left: -100%;
}

@keyframes marquee {
	from {
		left: 100%;
	}

	to {
		left: -100%;
	}
}

/* ========== GLOBAL ========== */
body {
  font-family: 'Segoe UI', sans-serif;
  background-color: var(--bg-light);
  margin: 0;
  padding: 0;
  color: var(--text-dark);
}

a {
  text-decoration: none;
  color: var(--primary-color);
}

a:hover {
  text-decoration: underline;
}

button {
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 10px 16px;
  cursor: pointer;
  border-radius: var(--border-radius);
  font-size: 14px;
  transition: var(--transition);
}

button:hover {
  background-color: var(--primary-dark);
}

h1, h2, h3 {
  color: #2a2;
}

/* ========== HEADER & FOOTER ========== */
    header {
      background-color: #2c3e50;
      color: white;
      padding: 15px;
      text-align: center;
    }

header h1 {
  margin: 0;
  font-size: 2.5rem;
}

nav {
  margin-top: 10px;
}

    nav a {
      color: #ecf0f1;
      text-decoration: none;
      margin: 0 15px;
    }

nav a:hover {
  text-decoration: underline;
}


/* ========== MAIN SECTION ========== */
main {
  padding: 30px;
  max-width: 1200px;
  margin: auto;
}

/* ========== PRODUITS ========== */

  .produits {
      display: flex;
      flex-wrap: wrap;
      gap: 20px;
      justify-content: center;
    }

 .produit {
      background: white;
      border-radius: 10px;
      box-shadow: 0 2px 8px rgba(0,0,0,0.1);
      padding: 15px;
      width: 260px;
      text-align: center;
      position: relative;
      transition: transform 0.2s;
    }

    .produit:hover {
        transform: scale(1.02);
  transition: transform 0.2s ease;
    }
    .produit img {
      max-width: 100%;
      height: auto;
      border-radius: 5px;
    }

.produit h3 {
      margin: 10px 0;
      font-size: 18px;
      color: #2c3e50;
}

.produit p {
  margin: 10px 0;
}

.quantite-input {
  width: 60px;
  padding: 5px;
  border-radius: 5px;
  border: 1px solid #ccc;
  text-align: center;
  margin-top: 5px;
}

.supprimer {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--danger-color);
  color: var(--white);
  border: none;
  border-radius: 5px;
  padding: 4px 8px;
  cursor: pointer;
  transition: var(--transition);
}

.supprimer:hover {
  background: var(--danger-dark);
}

.actions-panier {
  text-align: center;
  margin-top: 30px;
}

.actions-panier button,
.actions-panier a button {
  padding: 10px 20px;
  border: none;
  background: #3498db;
  color: var(--white);
  font-weight: bold;
  border-radius: 8px;
  margin: 5px;
  cursor: pointer;
  transition: var(--transition);
}

.actions-panier button:hover,
.actions-panier a button:hover {
  background: #2980b9;
}

/* ========== FORMULAIRES ========== */
form {
  margin-top: 20px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea {
  width: 100%;
  padding: 10px;
  margin-top: 8px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* ========== TABLES (ADMIN) ========== */
.table-admin {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  background-color: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.table-admin th,
.table-admin td {
  padding: 12px;
  border: 1px solid #ddd;
  text-align: left;
  font-size: 1rem;
}

.table-admin th {
  background-color: #333;
  color: var(--white);
}

.table-admin tr:nth-child(even) {
  background-color: #f9f9f9;
}

.table-admin tr:hover {
  background-color: #e1e1e1;
}

.admin-actions {
  display: flex;
  gap: 10px;
}

.admin-actions a {
  color: var(--white);
  padding: 6px 12px;
  border-radius: 4px;
  transition: background 0.2s;
}

.admin-actions a.modify {
  background-color: #28a745;
}

.admin-actions a.modify:hover {
  background-color: #218838;
}

.admin-actions a.delete {
  background-color: #dc3545;
}

.admin-actions a.delete:hover {
  background-color: #c82333;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  nav a {
    display: block;
    margin: 10px 0;
  }

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

  .table-admin th,
  .table-admin td {
    font-size: 0.9rem;
    padding: 8px;
  }

  .admin-actions {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ========== IMPRESSION ========== */
@media print {
  nav, header, footer, button {
    display: none !important;
  }

  table {
    width: 100%;
    border-collapse: collapse;
  }

  table, th, td {
    border: 1px solid #000;
  }
}

/*==footer==*/
footer {
  background-color: #2c3e50;
  color: white;
  padding: 30px 20px 10px;
  margin-top: 40px;
  font-size: 14px;
}

.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px;
  max-width: 1200px;
  margin: auto;
}

.footer-section {
  flex: 1 1 220px;
  min-width: 200px;
}

.footer-section h3, .footer-section h4 {
  margin-bottom: 8px;
  color: #a2ffb1;
}

.footer-section p, .footer-section a {
  color: #ecf0f1;
  margin: 4px 0;
  text-decoration: none;
}

.footer-section a:hover {
  text-decoration: underline;
}

.footer-bottom {
  text-align: center;
  margin-top: 20px;
  border-top: 1px solid #ccc;
  padding-top: 10px;
  font-size: 13px;
  color: #bbb;
}
.btn-maps {
  display: inline-block;
  padding: 10px 15px;
  background-color: #4CAF50;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.btn-maps:hover {
  background-color: #45a049;
}
.burger {
  display: none;
  font-size: 24px;
  cursor: pointer;
  color: white;
  margin-top: 10px;
}

@media (max-width: 600px) {
  .burger {
    display: block;
  }

  nav {
    display: none;
    flex-direction: column;
    align-items: flex-start;
  }

  nav.show {
    display: flex;
  }

  .user-info {
    margin-left: 0;
    margin-top: 10px;
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .produit {
    width: 100%;
    padding: 10px;
  }

  .produit h3 {
    font-size: 16px;
  }

  .produit button {
    font-size: 14px;
    padding: 8px 12px;
  }
}
.commentaire div a {
  text-decoration: none;
  color: #333;
  font-size: 14px;
  padding: 4px 6px;
  border-radius: 5px;
  background: #f0f0f0;
  margin-right: 8px;
}

.commentaire div a:hover {
  background: #ddd;
}

