/* ===========================================================
   matelas-maroc.com — design system
   Palette proposée (aucune charte graphique fournie — à valider)
   =========================================================== */

:root {
  --navy: #17264A;
  --navy-light: #253B6E;
  --gold: #B08D3F;
  --gold-light: #D9C08C;
  --bg: #FAF7F2;
  --bg-alt: #F0EAE0;
  --text: #2E2E33;
  --text-muted: #63636B;
  --border: #E4DCCB;
  --white: #FFFFFF;
  --success-bg: #EAF3EA;
  --font-head: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius: 10px;
  --shadow: 0 2px 16px rgba(23, 38, 74, 0.08);
  --shadow-lg: 0 8px 32px rgba(23, 38, 74, 0.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--gold); }
h1, h2, h3 { font-family: var(--font-head); color: var(--navy); line-height: 1.25; margin: 0 0 0.6em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); font-weight: 600; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 600; margin-top: 0.2em; }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1em; }
.lead { font-size: 1.15rem; color: var(--text-muted); }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 1.25rem; }
.section { padding: 3.5rem 0; }
.section-alt { background: var(--bg-alt); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: start; }
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 0.4em;
  padding: 0.7em 1.4em; border-radius: 999px; font-weight: 600; font-size: 0.95rem;
  border: 2px solid transparent; cursor: pointer; white-space: nowrap;
}
.btn-primary { background: var(--gold); color: var(--white); }
.btn-primary:hover { background: #98782F; color: var(--white); }
.btn-outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.btn-ghost { color: var(--navy); background: transparent; border-color: transparent; padding: 0.6em 0.8em; }
.btn-light { background: var(--white); color: var(--navy); }
.btn-light:hover { background: var(--gold-light); color: var(--navy); }
.btn-lg { padding: 0.9em 1.8em; font-size: 1.05rem; }
.btn-sm { padding: 0.5em 1.1em; font-size: 0.85rem; }

/* Header */
.site-header { background: var(--white); position: sticky; top: 0; z-index: 50; box-shadow: var(--shadow); }
.header-inner { display: flex; align-items: center; gap: 1.5rem; padding: 0.8rem 1.25rem; }
.logo { display: flex; align-items: center; gap: 0.6rem; flex-shrink: 0; }
.logo-mark {
  width: 42px; height: 42px; border-radius: 50%; background: var(--navy);
  color: var(--gold-light); font-family: var(--font-head); font-weight: 600; font-size: 1.05rem;
  display: flex; align-items: center; justify-content: center;
}
.logo-text { font-family: var(--font-head); font-size: 0.95rem; line-height: 1.05; color: var(--navy); }
.logo-text strong { color: var(--gold); }
.site-nav { display: none; gap: 1.4rem; margin-left: 1rem; flex: 1; }
.nav-link { font-size: 0.92rem; font-weight: 500; color: var(--text); white-space: nowrap; }
.nav-link.is-active, .nav-link:hover { color: var(--gold); }
.header-cta { display: none; gap: 0.6rem; margin-left: auto; }
.nav-toggle {
  margin-left: auto; background: none; border: none; width: 40px; height: 40px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; cursor: pointer;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--navy); border-radius: 2px; }
.mobile-nav {
  display: none; flex-direction: column; gap: 0; background: var(--white); border-top: 1px solid var(--border);
  padding: 0.5rem 1.25rem 1.25rem;
}
.mobile-nav.is-open { display: flex; }
.mobile-nav .nav-link { padding: 0.7rem 0; border-bottom: 1px solid var(--border); }
.mobile-nav .btn { margin-top: 0.8rem; justify-content: center; }

@media (min-width: 980px) {
  .site-nav { display: flex; }
  .header-cta { display: flex; }
  .nav-toggle { display: none; }
  .mobile-nav { display: none !important; }
}

/* Breadcrumb */
.breadcrumb { background: var(--bg-alt); font-size: 0.85rem; padding: 0.6rem 0; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb .sep { margin: 0 0.3em; }
.breadcrumb [aria-current="page"] { color: var(--navy); font-weight: 600; }

/* Hero */
.hero { background: linear-gradient(180deg, var(--bg-alt), var(--bg)); padding: 3rem 0 3.5rem; }
.hero-inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 2.5rem; align-items: center; }
.hero-media img { border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.hero-actions { display: flex; gap: 0.8rem; flex-wrap: wrap; margin-top: 1.4rem; }
@media (max-width: 860px) { .hero-inner { grid-template-columns: 1fr; } .hero-media { order: -1; } }

.page-hero { padding: 3rem 0 1rem; }

/* Cards */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
@media (max-width: 980px) { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .card-grid { grid-template-columns: 1fr; } }
.card { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.product-card .card-media { display: block; aspect-ratio: 3/2; overflow: hidden; background: var(--bg-alt); }
.product-card .card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 1.2rem 1.3rem 1.4rem; }
.card-body h3 { margin-bottom: 0.3em; font-size: 1.1rem; }
.card-tagline { color: var(--text-muted); font-size: 0.92rem; margin-bottom: 0.6em; }
.card-price { font-weight: 700; color: var(--navy); margin-bottom: 0.8em; }
.card-price-lg { font-size: 1.4rem; }
.brand-badge { display: inline-block; font-size: 0.6em; font-family: var(--font-body); font-weight: 600; background: var(--navy); color: var(--gold-light); padding: 0.2em 0.6em; border-radius: 999px; vertical-align: middle; }

.img-placeholder {
  width: 100%; height: 100%; min-height: 180px; display: flex; align-items: center; justify-content: center;
  background: repeating-linear-gradient(45deg, var(--bg-alt), var(--bg-alt) 10px, var(--border) 10px, var(--border) 20px);
  color: var(--text-muted); font-size: 0.9rem; text-align: center; padding: 1rem;
}
.img-placeholder-lg { min-height: 340px; border-radius: var(--radius); font-size: 1rem; }

/* Lists */
.check-list { list-style: none; padding: 0; margin: 0 0 1.2em; }
.check-list li { padding-left: 1.6em; position: relative; margin-bottom: 0.6em; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--gold); font-weight: 700; }
.contact-list { list-style: none; padding: 0; }
.contact-list li { margin-bottom: 0.7em; }
.footer-list { list-style: none; padding: 0; margin: 0; }
.footer-list li { margin-bottom: 0.5em; }

/* Table */
.data-table { width: 100%; border-collapse: collapse; background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.data-table th, .data-table td { text-align: left; padding: 0.8em 1em; border-bottom: 1px solid var(--border); font-size: 0.95rem; }
.data-table th { background: var(--navy); color: var(--white); font-weight: 600; }
.data-table tr:last-child td { border-bottom: none; }

/* FAQ */
.faq-list { display: flex; flex-direction: column; gap: 0.7rem; }
.faq-item { background: var(--white); border-radius: var(--radius); padding: 1rem 1.3rem; box-shadow: var(--shadow); }
.faq-item summary { cursor: pointer; font-weight: 600; color: var(--navy); }
.faq-item p { margin-top: 0.7em; margin-bottom: 0; color: var(--text-muted); }

/* CTA band */
.cta-band { background: var(--navy); color: var(--white); padding: 2.2rem 0; }
.cta-band-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.cta-band p { margin: 0; font-size: 1.15rem; font-family: var(--font-head); max-width: 32ch; }
.cta-band-actions { display: flex; gap: 0.8rem; flex-wrap: wrap; }

/* Product page */
.product-hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: start; }
@media (max-width: 860px) { .product-hero-grid { grid-template-columns: 1fr; } }
.product-media img { border-radius: var(--radius); box-shadow: var(--shadow-lg); margin-bottom: 0.8rem; }
.detail-thumb { max-width: 220px; }
.note-inline { background: #FFF6E5; color: #8A5A00; padding: 0.6em 1em; border-radius: 8px; font-size: 0.9rem; display: inline-block; }
.fine-print { color: var(--text-muted); font-size: 0.85rem; }

/* Contact form */
.contact-form { display: flex; flex-direction: column; gap: 0.4rem; background: var(--white); padding: 1.6rem; border-radius: var(--radius); box-shadow: var(--shadow); }
.contact-form label { font-weight: 600; font-size: 0.9rem; margin-top: 0.6rem; }
.contact-form input, .contact-form textarea {
  padding: 0.7em 0.9em; border: 1px solid var(--border); border-radius: 8px; font-family: var(--font-body); font-size: 0.95rem;
}
.contact-form button { margin-top: 1rem; align-self: flex-start; }

/* Footer */
.site-footer { background: var(--navy); color: #C9D0E0; padding: 3rem 0 1.5rem; margin-top: 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 2rem; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h3 { color: var(--gold-light); font-size: 1rem; margin-bottom: 0.8em; }
.site-footer a { color: #C9D0E0; }
.site-footer a:hover { color: var(--gold-light); }
.logo-footer .logo-text { color: var(--white); }
.footer-desc { color: #A9B3CC; font-size: 0.9rem; margin-top: 0.8rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.12); margin-top: 2.5rem; padding-top: 1.2rem; font-size: 0.8rem; color: #8B96B8; }
