* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --navy: #0d2137;
  --blue: #1e6fc5;
  --blue-light: #e8f1fb;
  --accent: #f0a500;
  --text: #2c2c2c;
  --text-light: #6b7280;
  --bg: #f5f7fa;
  --white: #ffffff;
  --border: #e2e8f0;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --radius: 10px;
}

body {
  font-family: 'Segoe UI', Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

/* ── HEADER ── */
header {
  background: var(--navy);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo-img {
  height: 48px;
  background: white;
  padding: 3px 8px;
  border-radius: 7px;
  display: block;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 8px;
}

nav ul a {
  color: #cbd5e1;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  transition: all 0.2s;
}

nav ul a:hover,
nav ul a.active {
  background: var(--blue);
  color: var(--white);
}

/* ── HERO BAND ── */
.hero-band {
  background: linear-gradient(135deg, var(--navy) 0%, #1a4a7a 100%);
  color: var(--white);
  text-align: center;
  padding: 48px 24px;
}

.hero-band h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.hero-band p {
  color: #94a3b8;
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto;
}

/* ── PRODUCTS PAGE ── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 28px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--blue);
  display: inline-block;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid var(--border);
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.product-card a {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-img-wrap {
  background: #f8fafc;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 220px;
  border-bottom: 1px solid var(--border);
}

.product-img-wrap img {
  max-width: 100%;
  max-height: 180px;
  object-fit: contain;
}

.product-info {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 8px;
  line-height: 1.4;
}

.product-desc {
  font-size: 0.875rem;
  color: var(--text-light);
  flex: 1;
  margin-bottom: 16px;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.product-price {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--blue);
}

.product-price .old-price {
  font-size: 0.85rem;
  color: var(--text-light);
  text-decoration: line-through;
  font-weight: 400;
  margin-left: 6px;
}

.btn-detail {
  background: var(--navy);
  color: var(--white);
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-detail:hover {
  background: var(--blue);
}

.badge-promo {
  background: #ef4444;
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  margin-bottom: 8px;
  display: inline-block;
}

/* ── PRODUCT DETAIL PAGE ── */
.breadcrumb {
  font-size: 0.875rem;
  color: var(--text-light);
  margin-bottom: 24px;
}

.breadcrumb a {
  color: var(--blue);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.product-detail-img {
  background: #f8fafc;
  border-radius: 8px;
  padding: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 380px;
}

.product-detail-img img {
  max-width: 100%;
  max-height: 340px;
  object-fit: contain;
}

.product-detail-info h1 {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 16px;
  line-height: 1.3;
}

.product-detail-price {
  font-size: 2rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 6px;
}

.product-detail-price .old {
  font-size: 1.1rem;
  color: var(--text-light);
  text-decoration: line-through;
  font-weight: 400;
  margin-left: 10px;
}

.product-detail-desc {
  color: var(--text-light);
  margin: 20px 0;
  line-height: 1.7;
}

.features-list {
  list-style: none;
  margin: 16px 0 24px;
}

.features-list li {
  padding: 6px 0;
  padding-left: 22px;
  position: relative;
  font-size: 0.95rem;
  color: var(--text);
}

.features-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--blue);
  font-weight: 700;
}

.guarantees {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.guarantee-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--text-light);
}

.guarantee-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

.btn-contact-product {
  display: inline-block;
  background: var(--blue);
  color: white;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  margin-top: 20px;
  transition: background 0.2s;
}

.btn-contact-product:hover {
  background: var(--navy);
}

/* ── CONTACT PAGE ── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 40px;
}

.contact-info-card {
  background: var(--navy);
  color: white;
  border-radius: var(--radius);
  padding: 36px;
}

.contact-info-card h2 {
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.contact-info-card p {
  color: #94a3b8;
  margin-bottom: 32px;
  font-size: 0.95rem;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
}

.contact-item-icon {
  font-size: 1.4rem;
  margin-top: 2px;
}

.contact-item-label {
  font-size: 0.8rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.contact-item-value {
  font-size: 0.95rem;
  font-weight: 500;
}

.contact-form-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.contact-form-card h2 {
  font-size: 1.4rem;
  color: var(--navy);
  margin-bottom: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--text);
  background: var(--bg);
  transition: border-color 0.2s;
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--blue);
  background: white;
}

.form-group textarea {
  height: 120px;
  resize: vertical;
}

.btn-submit {
  background: var(--blue);
  color: white;
  border: none;
  padding: 12px 28px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: var(--navy);
}

/* ── FOOTER ── */
footer {
  background: var(--navy);
  color: #94a3b8;
  margin-top: 64px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 24px 32px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer-text-logo {
  font-size: 1.3rem;
  font-weight: 700;
  color: white;
  letter-spacing: 1.5px;
  margin-bottom: 12px;
}

.footer-text-logo span { color: var(--accent); }

.footer-inner > div > p {
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.6;
  margin-top: 4px;
}

.footer-col-title {
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 14px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-col a, footer a {
  color: #94a3b8;
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.footer-col a:hover, footer a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 20px 24px;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: #64748b;
}

/* ── LEGAL PAGES ── */
.legal-content {
  background: var(--white);
  border-radius: var(--radius);
  padding: 48px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  max-width: 860px;
  margin: 0 auto;
}

.legal-content h2 {
  font-size: 1.2rem;
  color: var(--navy);
  font-weight: 700;
  margin: 32px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--blue-light);
}

.legal-content h2:first-child { margin-top: 0; }

.legal-content p {
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.75;
  margin-bottom: 10px;
}

.legal-content ul {
  padding-left: 20px;
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.75;
  margin-bottom: 10px;
}

.legal-info-box {
  background: var(--blue-light);
  border-left: 4px solid var(--blue);
  border-radius: 0 8px 8px 0;
  padding: 20px 24px;
  margin-bottom: 32px;
}

.legal-info-box p { margin: 0; color: var(--navy); font-weight: 500; }

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .hero-band h1 { font-size: 1.5rem; }
  .products-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
  .product-detail { grid-template-columns: 1fr; gap: 24px; padding: 24px; }
  .contact-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .guarantees { grid-template-columns: 1fr; }
  nav ul a { padding: 6px 10px; font-size: 0.85rem; }
  .legal-content { padding: 28px 20px; }
}

@media (max-width: 480px) {
  .products-grid { grid-template-columns: 1fr; }
  .container { padding: 24px 16px; }
  .footer-inner { grid-template-columns: 1fr; gap: 24px; }
}

/* ══════════════════════════════════════
   PANIER
══════════════════════════════════════ */

/* Icône panier dans la nav */
.cart-icon-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #cbd5e1;
  position: relative;
  display: flex;
  align-items: center;
  padding: 6px 8px;
  margin-left: 4px;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s;
}
.cart-icon-btn:hover { background: var(--blue); color: white; }

#cart-badge {
  position: absolute;
  top: 0;
  right: 0;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 0.68rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

/* Overlay sombre */
#cart-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 300;
  cursor: pointer;
}
#cart-overlay.open { display: block; }

/* Sidebar */
#cart-sidebar {
  position: fixed;
  top: 0;
  right: -440px;
  width: 420px;
  max-width: 96vw;
  height: 100vh;
  background: white;
  z-index: 301;
  display: flex;
  flex-direction: column;
  transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -6px 0 32px rgba(0, 0, 0, 0.18);
}
#cart-sidebar.open { right: 0; }

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  background: var(--navy);
  color: white;
  flex-shrink: 0;
}
.cart-header h3 { margin: 0; font-size: 1.05rem; font-weight: 700; }

.cart-close-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color 0.2s;
}
.cart-close-btn:hover { color: white; }

/* Liste des articles */
#cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}
.cart-empty {
  color: #9ca3af;
  text-align: center;
  margin-top: 48px;
  font-size: 0.95rem;
}

.cart-item {
  border-bottom: 1px solid #f1f5f9;
  padding: 14px 0;
}
.cart-item:last-child { border-bottom: none; }

.cart-item-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
}
.cart-item-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy);
  flex: 1;
  line-height: 1.4;
}
.cart-item-line {
  font-weight: 700;
  color: var(--blue);
  white-space: nowrap;
  font-size: 0.95rem;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}
.qty-btn {
  width: 28px;
  height: 28px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background 0.15s;
}
.qty-btn:hover { background: #e2e8f0; }

.qty-val {
  min-width: 22px;
  text-align: center;
  font-weight: 700;
  font-size: 0.9rem;
}

.remove-btn {
  background: none;
  border: none;
  color: #cbd5e1;
  cursor: pointer;
  font-size: 0.8rem;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color 0.15s;
  margin-left: 2px;
}
.remove-btn:hover { color: #ef4444; }

.cart-unit-price {
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 4px;
}

/* Footer panier */
.cart-footer {
  border-top: 1px solid #e2e8f0;
  padding: 20px 20px 24px;
  background: #f8fafc;
  flex-shrink: 0;
}
.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 0.95rem;
  color: var(--text);
}
.cart-total-row strong {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
}

#cart-pay-btn {
  width: 100%;
  background: var(--blue);
  color: white;
  border: none;
  padding: 14px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  letter-spacing: 0.3px;
}
#cart-pay-btn:hover:not(:disabled) { background: var(--navy); }
#cart-pay-btn:disabled { background: #94a3b8; cursor: not-allowed; }

.cart-secure {
  text-align: center;
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 10px;
  margin-bottom: 0;
}

/* Bouton Ajouter au panier sur les fiches produit */
.btn-add-cart {
  display: block;
  width: 100%;
  background: var(--blue);
  color: white;
  border: none;
  padding: 14px 24px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 20px;
  transition: background 0.2s;
  text-align: center;
}
.btn-add-cart:hover { background: var(--navy); }

.btn-contact-secondary {
  display: block;
  text-align: center;
  color: var(--text-light);
  font-size: 0.85rem;
  margin-top: 10px;
  text-decoration: none;
  transition: color 0.2s;
}
.btn-contact-secondary:hover { color: var(--blue); text-decoration: underline; }
