/* ===========================================
   CHRONO 26 — STYLESHEET PRINCIPAL
   =========================================== */

:root {
  --noir: #0a0a0a;
  --noir-profond: #050505;
  --or: #c9a961;
  --or-clair: #e4c989;
  --or-sombre: #8a7340;
  --ivoire: #f5f1e8;
  --gris-cendre: #1a1a1a;
  --gris-fume: #2a2a2a;
  --texte-doux: #a8a39a;
  --bordure: rgba(201, 169, 97, 0.15);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--noir-profond);
  color: var(--ivoire);
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
  opacity: 0.04;
  pointer-events: none;
  z-index: 1000;
  mix-blend-mode: overlay;
}

img, svg, video { max-width: 100%; height: auto; display: block; }

/* ============ TOP BAR ============ */
.top-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: rgba(5, 5, 5, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--bordure);
  z-index: 100;
  padding: 18px 50px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: padding 0.4s ease, background 0.4s ease;
}

.top-bar.scrolled {
  padding-top: 14px;
  padding-bottom: 14px;
  background: rgba(5, 5, 5, 0.98);
}

.logo-mark {
  font-family: 'Italiana', serif;
  font-size: 28px;
  letter-spacing: 0.18em;
  color: var(--ivoire);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark .num { color: var(--or); font-weight: 400; }

.top-bar > nav ul {
  list-style: none;
  display: flex;
  gap: 42px;
  align-items: center;
}

.top-bar > nav a {
  color: var(--ivoire);
  text-decoration: none;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  position: relative;
  transition: color 0.3s ease;
}

.top-bar > nav a:hover { color: var(--or); }

.top-bar > nav a::after {
  content: '';
  position: absolute;
  bottom: -6px; left: 0;
  width: 0; height: 1px;
  background: var(--or);
  transition: width 0.4s ease;
}

.top-bar > nav a:hover::after { width: 100%; }

.lang-switcher {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 11px;
  letter-spacing: 0.18em;
}

.lang-switcher button {
  background: none;
  border: none;
  color: var(--texte-doux);
  cursor: pointer;
  font-family: inherit;
  font-size: 11px;
  letter-spacing: 0.18em;
  padding: 4px 8px;
  transition: color 0.3s ease;
}

.lang-switcher button.active { color: var(--or); }
.lang-switcher button:hover { color: var(--ivoire); }
.lang-sep { color: var(--or-sombre); opacity: 0.5; }

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--ivoire);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 8px;
}

.mobile-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: var(--noir-profond);
  z-index: 101;
  transform: translateY(-100%);
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 100px 30px 50px;
  border-bottom: 1px solid var(--bordure);
}

.mobile-nav.open { transform: translateY(0); }
.mobile-nav ul { list-style: none; }
.mobile-nav li { border-bottom: 1px solid var(--bordure); }
.mobile-nav a {
  display: block;
  padding: 22px 0;
  color: var(--ivoire);
  text-decoration: none;
  font-family: 'Italiana', serif;
  font-size: 22px;
  letter-spacing: 0.05em;
}
.mobile-nav a:hover { color: var(--or); }

/* ============ SECTIONS ============ */
section { padding: 140px 50px; position: relative; }

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 10px;
  letter-spacing: 0.4em;
  color: var(--or);
  text-transform: uppercase;
  margin-bottom: 30px;
}

.section-title {
  font-family: 'Italiana', serif;
  font-size: clamp(40px, 6vw, 80px);
  line-height: 1.05;
  font-weight: 400;
  margin-bottom: 30px;
  letter-spacing: 0.01em;
}

.section-title em {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: var(--or);
  font-weight: 300;
}

/* ============ BOUTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 18px 38px;
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  text-decoration: none;
  font-weight: 400;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid var(--or);
  background: transparent;
  color: var(--ivoire);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--or);
  transform: translateY(101%);
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: -1;
}

.btn:hover::before { transform: translateY(0); }
.btn:hover { color: var(--noir); border-color: var(--or-clair); }

.btn-primary {
  background: var(--or);
  color: var(--noir);
  border-color: var(--or);
}
.btn-primary::before { background: var(--or-clair); }
.btn-primary:hover { color: var(--noir); }

/* ============ WHATSAPP FLOATING ============ */
.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, #1f1f1f, #0a0a0a);
  border: 1px solid var(--or);
  padding: 14px 22px 14px 18px;
  border-radius: 50px;
  text-decoration: none;
  color: var(--ivoire);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 0 0 rgba(201, 169, 97, 0.4);
  transition: transform 0.4s ease, background 0.4s ease;
  animation: pulseGold 3s infinite;
}

@keyframes pulseGold {
  0%, 100% { box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 0 0 rgba(201, 169, 97, 0.4); }
  50% { box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 0 12px rgba(201, 169, 97, 0); }
}

.whatsapp-float:hover {
  transform: translateY(-3px);
  background: linear-gradient(135deg, var(--or), var(--or-sombre));
  color: var(--noir);
}

.whatsapp-float .wa-icon {
  width: 24px;
  height: 24px;
  color: #25D366;
  flex-shrink: 0;
  transition: color 0.3s ease;
}

.whatsapp-float:hover .wa-icon { color: var(--noir); }
.whatsapp-float .wa-text { display: flex; flex-direction: column; line-height: 1.2; }
.whatsapp-float .wa-label {
  font-size: 9px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  opacity: 0.7;
}
.whatsapp-float .wa-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 16px;
  font-weight: 500;
}

/* ============ FOOTER ============ */
footer {
  background: var(--noir);
  border-top: 1px solid var(--bordure);
  padding: 80px 50px 30px;
}

.footer-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.footer-brand .logo-mark { margin-bottom: 24px; }
.footer-tagline {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: var(--texte-doux);
  font-size: 16px;
  line-height: 1.6;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 11px;
  letter-spacing: 0.3em;
  color: var(--or);
  text-transform: uppercase;
  margin-bottom: 24px;
  font-weight: 500;
}

.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 14px; }
.footer-col a {
  color: var(--texte-doux);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.3s ease;
}
.footer-col a:hover { color: var(--or); }

.footer-bottom {
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid var(--bordure);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-legal {
  font-size: 11px;
  color: var(--texte-doux);
  letter-spacing: 0.05em;
  line-height: 1.7;
}

.footer-legal strong { color: var(--ivoire); font-weight: 400; }

.footer-socials { display: flex; gap: 16px; }
.footer-socials a {
  width: 36px;
  height: 36px;
  border: 1px solid var(--bordure);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--texte-doux);
  text-decoration: none;
  transition: all 0.3s ease;
}
.footer-socials a:hover { border-color: var(--or); color: var(--or); }
.footer-socials svg { width: 14px; height: 14px; }

/* ============ COOKIE BANNER ============ */
.cookie-banner {
  position: fixed;
  bottom: 30px;
  left: 30px;
  z-index: 300;
  background: linear-gradient(135deg, var(--gris-cendre), var(--noir));
  border: 1px solid var(--or);
  padding: 28px;
  max-width: 440px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
  transform: translateY(120%);
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.cookie-banner.show { transform: translateY(0); }

.cookie-banner h4 {
  font-family: 'Italiana', serif;
  font-size: 22px;
  color: var(--or);
  margin-bottom: 12px;
  letter-spacing: 0.05em;
  font-weight: 400;
}

.cookie-banner p {
  font-size: 13px;
  color: var(--texte-doux);
  line-height: 1.6;
  margin-bottom: 20px;
}

.cookie-banner p a {
  color: var(--or);
  text-decoration: underline;
}

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

.cookie-actions button {
  padding: 12px 22px;
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid var(--or);
  transition: all 0.3s ease;
  background: transparent;
  color: var(--ivoire);
  font-weight: 400;
  flex: 1;
  min-width: 110px;
}

.cookie-actions button.accept {
  background: var(--or);
  color: var(--noir);
}

.cookie-actions button:hover {
  background: var(--or-clair);
  color: var(--noir);
}

/* ============ LEGAL PAGES ============ */
.legal-hero {
  padding: 200px 50px 80px;
  background: 
    radial-gradient(ellipse at 50% 0%, rgba(201, 169, 97, 0.1) 0%, transparent 60%),
    var(--noir-profond);
  text-align: center;
  border-bottom: 1px solid var(--bordure);
}

.legal-hero .section-label { justify-content: center; }
.legal-hero h1 {
  font-family: 'Italiana', serif;
  font-size: clamp(40px, 7vw, 80px);
  font-weight: 400;
  letter-spacing: 0.01em;
  margin-bottom: 20px;
  background: linear-gradient(180deg, var(--ivoire) 0%, var(--or-clair) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.legal-hero p {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 18px;
  color: var(--texte-doux);
  max-width: 600px;
  margin: 0 auto;
}

.legal-content {
  max-width: 880px;
  margin: 0 auto;
  padding: 80px 50px 120px;
}

.legal-content h2 {
  font-family: 'Italiana', serif;
  font-size: 32px;
  color: var(--ivoire);
  margin: 60px 0 20px;
  font-weight: 400;
  letter-spacing: 0.02em;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--bordure);
}

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

.legal-content h3 {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 22px;
  color: var(--or);
  margin: 32px 0 14px;
  font-weight: 500;
}

.legal-content p {
  color: var(--texte-doux);
  font-size: 15px;
  line-height: 1.85;
  margin-bottom: 18px;
}

.legal-content ul, .legal-content ol {
  margin: 18px 0 18px 24px;
  color: var(--texte-doux);
}

.legal-content li {
  margin-bottom: 10px;
  font-size: 15px;
  line-height: 1.8;
}

.legal-content li::marker { color: var(--or); }

.legal-content a { color: var(--or); text-decoration: underline; }
.legal-content a:hover { color: var(--or-clair); }

.legal-content strong { color: var(--ivoire); font-weight: 400; }

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
}

.legal-content .table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 24px 0;
  border: 1px solid var(--bordure);
}
.legal-content .table-wrap table {
  margin: 0;
  min-width: 520px;
}
.legal-content .table-wrap::-webkit-scrollbar { height: 6px; }
.legal-content .table-wrap::-webkit-scrollbar-thumb { background: var(--or-sombre); border-radius: 3px; }
.legal-content .table-wrap::-webkit-scrollbar-track { background: var(--gris-cendre); }

.legal-content th, .legal-content td {
  padding: 14px 18px;
  text-align: left;
  border: 1px solid var(--bordure);
  color: var(--texte-doux);
}

.legal-content th {
  background: var(--gris-cendre);
  color: var(--or);
  font-weight: 400;
  letter-spacing: 0.05em;
  font-size: 12px;
  text-transform: uppercase;
}

.legal-content .highlight-box {
  background: var(--gris-cendre);
  border-left: 3px solid var(--or);
  padding: 24px 28px;
  margin: 30px 0;
}

.legal-content .highlight-box p:last-child { margin-bottom: 0; }

.last-update {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.25em;
  color: var(--or);
  text-transform: uppercase;
  margin-bottom: 30px;
  padding: 8px 16px;
  border: 1px solid var(--bordure);
}

/* ============ SCROLL REVEAL ============ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s ease, transform 1s ease;
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ============ RESPONSIVE ============ */
@media (max-width: 1200px) {
  .top-bar { padding: 18px 30px; }
  .top-bar > nav ul { gap: 28px; }
  section { padding: 120px 30px; }
  footer { padding: 70px 30px 30px; }
}

@media (max-width: 1024px) {
  .top-bar > nav ul { gap: 22px; }
  .top-bar > nav a { font-size: 10px; letter-spacing: 0.18em; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 50px; }
}

@media (max-width: 860px) {
  .top-bar { padding: 14px 20px; }
  .top-bar > nav ul { display: none; }
  .menu-toggle { display: block; }
  .lang-switcher {
    margin-left: auto;
    margin-right: 14px;
    gap: 4px;
  }
  .lang-switcher button { padding: 4px 5px; font-size: 10px; letter-spacing: 0.1em; }
  .logo-mark { font-size: 22px; letter-spacing: 0.14em; }
  section { padding: 90px 20px; }
  .legal-hero { padding: 140px 20px 60px; }
  .legal-content { padding: 60px 20px 80px; }
  .footer-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 20px; }
  footer { padding: 60px 20px 30px; }
  .whatsapp-float .wa-text { display: none; }
  .whatsapp-float { padding: 14px; bottom: 20px; right: 20px; }
  .cookie-banner {
    left: 16px;
    right: 16px;
    bottom: 90px;
    max-width: none;
    padding: 22px;
  }
  .cookie-banner h4 { font-size: 18px; }
  .cookie-actions button { font-size: 9px; padding: 11px 14px; }
}

@media (max-width: 480px) {
  .top-bar { padding: 12px 16px; }
  .logo-mark { font-size: 19px; }
  .lang-switcher { font-size: 9px; }
  .lang-switcher button { font-size: 9px; padding: 4px 3px; }
  .lang-sep { display: none; }
  section { padding: 70px 18px; }
  .section-title { font-size: clamp(32px, 9vw, 48px); }
  .legal-content h2 { font-size: 24px; }
  .legal-content p, .legal-content li { font-size: 14px; }
  .btn { padding: 16px 28px; font-size: 10px; letter-spacing: 0.22em; }
  .footer-legal { font-size: 10px; }
  .footer-grid { gap: 36px; margin-bottom: 40px; }
}

/* ============ RTL SUPPORT (Arabe) ============ */
html[dir="rtl"] body { font-family: 'Inter', 'Tajawal', sans-serif; }
html[dir="rtl"] .whatsapp-float { right: auto; left: 30px; }
html[dir="rtl"] .cookie-banner { left: auto; right: 30px; }
html[dir="rtl"] nav ul { flex-direction: row-reverse; }
html[dir="rtl"] .section-label::before { display: none; }
html[dir="rtl"] .legal-content .highlight-box { border-left: none; border-right: 3px solid var(--or); }

@media (max-width: 860px) {
  html[dir="rtl"] .whatsapp-float { left: 20px; }
  html[dir="rtl"] .cookie-banner { right: 16px; left: 16px; }
}

/* ============ PRINT ============ */
@media print {
  .top-bar, .whatsapp-float, .cookie-banner, footer .footer-socials, .menu-toggle, .mobile-nav {
    display: none !important;
  }
  body { background: white; color: black; }
  .legal-content { padding: 20px; max-width: 100%; }
  .legal-content h2, .legal-content h3 { color: black; }
  .legal-content p, .legal-content li { color: #333; }
  a { color: black; text-decoration: underline; }
}

/* Skip link accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--or);
  color: var(--noir);
  padding: 8px 16px;
  z-index: 1001;
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.skip-link:focus { top: 0; }

/* Focus states for keyboard navigation */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--or);
  outline-offset: 3px;
}
