/* ============================================================
   SalonHub — Design System (Integrated Premium Dark Mode)
   Identité : or bruni, verre fumé, contrastes or et blanc.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300;0,9..144,500;0,9..144,600;1,9..144,500&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  --ink:        #FFFFFF;          /* Texte principal blanc */
  --ink-soft:   #A3A3A3;          /* Texte secondaire gris doux */
  --cream:      transparent;      /* Transparence pour laisser voir le fond E-Shelle */
  --cream-2:    rgba(17, 24, 39, 0.6); /* Espace verre pour les cartes */
  --gold:       #E4C583;          /* Or E-Shelle */
  --gold-light: #F3E2B8;          /* Or éclatant */
  --wine:       #EC4899;          /* Rose Beauté / SalonHub */
  --wine-dark:  #BE185D;
  --sage:       #10B981;          /* Vert succès */
  --line:       rgba(255, 255, 255, 0.08); /* Bordures discrètes */
  --line-light: rgba(255, 255, 255, 0.14);
  --shadow:     0 20px 50px -15px rgba(0, 0, 0, 0.6);
  --radius:     18px;
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  --card-bg:    rgba(255, 255, 255, 0.03); /* Fond des cartes */
  --card-border: rgba(255, 255, 255, 0.07);
}

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

/* Force le fond sombre vert/noir de E-Shelle pour assurer la visibilité parfaite du texte */
body, html {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink) !important;
  background-color: #07130C !important;
  background-image: radial-gradient(circle at 50% 0%, #0B1D12 0%, #07130C 85%) !important;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

img { max-width: 100%; display: block; border-radius: 8px; }
a { color: inherit; text-decoration: none; transition: color 0.2s ease; }
button { font-family: inherit; cursor: pointer; transition: all 0.2s ease; }

.eyebrow { font-weight: 700; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
h1, h2, h3, .font-display { font-family: var(--font-display); font-weight: 600; line-height: 1.15; margin: 0; }
p { line-height: 1.6; color: var(--ink-soft); }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* --- BOUTONS --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  font-size: .88rem;
  letter-spacing: .01em;
  transition: all .2s cubic-bezier(0.4, 0, 0.2, 1);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,0.3); }
.btn-gold { background: var(--gold); color: #0D0E12; }
.btn-gold:hover { background: var(--gold-light); }
.btn-outline { border-color: var(--line-light); color: var(--ink); background: rgba(255,255,255,0.03); }
.btn-outline:hover { background: var(--ink); color: #0D0E12; }
.btn-wa { background: #25D366; color: #fff; }
.btn-wa:hover { background: #1ebd59; }
.btn-block { width: 100%; justify-content: center; }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }

/* --- SECTION HERO --- */
.hero {
  position: relative;
  background: radial-gradient(circle at 80% 10%, rgba(228, 197, 131, 0.08), transparent 60%);
  color: var(--ink);
  padding: 120px 0 70px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.hero h1 { font-size: clamp(2.2rem, 4.5vw, 3.5rem); max-width: 760px; margin-top: 14px; color: #fff; }
.hero h1 em { font-style: normal; color: var(--gold-light); }
.hero p.lead { max-width: 600px; margin-top: 18px; color: var(--ink-soft); font-size: 1.05rem; }

/* --- BARRE DE RECHERCHE PREMIUM --- */
.search-card {
  position: relative;
  z-index: 2;
  margin-top: 40px;
  background: rgba(17, 24, 39, 0.7);
  border: 1px solid var(--line-light);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.search-card input, .search-card select {
  border: none;
  background: rgba(255,255,255,0.04);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: .95rem;
  font-family: inherit;
  color: var(--ink);
  min-width: 160px;
  flex: 1;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}
.search-card input:focus, .search-card select:focus {
  outline: none;
  background: rgba(255,255,255,0.08);
  border-color: var(--gold);
}
.search-card select option {
  background: #0F172A;
  color: #fff;
}
.search-card .btn { margin: 0; height: 46px; }

/* --- FILTRES CHIPS --- */
.categories-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.chip {
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: .85rem;
  font-weight: 600;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.2s ease;
}
.chip.active, .chip:hover {
  background: var(--gold);
  color: #0D0E12;
  border-color: var(--gold);
}

.section { padding: 80px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 36px; flex-wrap: wrap; gap: 12px; }
.section-head h2 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); margin-top: 6px; color: #fff; }
.muted { color: var(--ink-soft); }

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

/* --- CARTE TICKET DE RENDEZ-VOUS --- */
.ticket {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all .25s cubic-bezier(0.4, 0, 0.2, 1);
}
.ticket:hover {
  transform: translateY(-5px);
  border-color: rgba(228, 197, 131, 0.35);
  box-shadow: 0 12px 40px rgba(228, 197, 131, 0.08);
}
.ticket .cover { position: relative; height: 180px; background: linear-gradient(135deg, #1F2937, #111827); }
.ticket .cover img { width: 100%; height: 100%; object-fit: cover; }
.ticket .kind-badge { position: absolute; top: 12px; left: 12px; background: rgba(17, 24, 39, 0.85); border: 1px solid rgba(255,255,255,0.08); color: var(--gold-light); font-size: .72rem; font-weight: 700; padding: 5px 12px; border-radius: 999px; letter-spacing: .03em; backdrop-filter: blur(4px); }
.ticket .verified { position: absolute; top: 12px; right: 12px; background: var(--gold); color: #0D0E12; font-size: .7rem; font-weight: 800; padding: 5px 10px; border-radius: 999px; }
.ticket .body { padding: 22px 22px 0; flex: 1; }
.ticket .body h3 { font-size: 1.25rem; color: #fff; }
.ticket .loc { font-size: .85rem; color: var(--ink-soft); margin-top: 6px; }

/* Effet coupon détachable ticket */
.ticket .stub {
  position: relative;
  margin-top: 20px;
  padding: 18px 22px;
  border-top: 1px dashed rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ticket .stub::before, .ticket .stub::after {
  content: "";
  position: absolute;
  top: -10px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #07090e; /* Fusionne avec le fond sombre global */
}
.ticket .stub::before { left: -10px; }
.ticket .stub::after { right: -10px; }
.ticket .stub .price { font-family: var(--font-display); font-size: 1.1rem; color: var(--gold); font-weight: 600; }
.ticket .stub a { font-weight: 700; font-size: .85rem; color: var(--ink); }
.ticket .stub a:hover { color: var(--gold-light); }

.filters-bar { background: rgba(255, 255, 255, 0.02); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 38px; }

/* --- DETAIL SALON --- */
.salon-hero { position: relative; height: 350px; background: #111827; border-radius: 0 0 28px 28px; overflow: hidden; }
.salon-hero img { width: 100%; height: 100%; object-fit: cover; opacity: .7; }
.salon-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 20%, rgba(7, 9, 14, 0.95)); }
.salon-identity { position: relative; margin-top: -100px; z-index: 2; display: flex; gap: 24px; align-items: flex-end; padding: 0 24px; }
.salon-logo { width: 120px; height: 120px; border-radius: 20px; background: rgba(17, 24, 39, 0.8); border: 4px solid var(--line-light); box-shadow: var(--shadow); overflow: hidden; flex-shrink: 0; }
.salon-logo img { width: 100%; height: 100%; object-fit: cover; }
.salon-title-block h1 { color: #fff; font-size: clamp(1.8rem, 3.2vw, 2.6rem); }
.salon-title-block .loc { color: var(--ink-soft); margin-top: 6px; font-size: .95rem; }

.detail-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; margin-top: 45px; align-items: flex-start; }
@media (max-width: 900px) { .detail-grid { grid-template-columns: 1fr; } }

.service-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--line); cursor: pointer; transition: all 0.2s ease; }
.service-row:last-child { border-bottom: none; }
.service-row:hover { padding-left: 8px; border-color: rgba(228, 197, 131, 0.3); }
.service-row .info h4 { font-family: var(--font-display); font-size: 1.08rem; font-weight: 600; color: #fff; }
.service-row .info p { font-size: .85rem; color: var(--ink-soft); margin: 6px 0 0; }
.service-row .meta { text-align: right; }
.service-row .meta .price { font-weight: 800; color: var(--gold); }
.service-row .meta .dur { display: block; font-size: .78rem; color: var(--ink-soft); margin-top: 2px; }
.service-row.selected { background: rgba(228, 197, 131, 0.06); border-radius: 12px; padding: 16px; margin: 0 -16px; border-bottom: 1px solid transparent; }

/* --- PANEL RESERVATION --- */
.booking-panel {
  position: sticky;
  top: 96px;
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.booking-panel h3 { font-size: 1.20rem; color: #fff; }
.day-strip { display: flex; gap: 8px; overflow-x: auto; padding: 18px 0 8px; scrollbar-width: none; }
.day-strip::-webkit-scrollbar { display: none; }
.day-pill { flex: 0 0 auto; width: 60px; padding: 12px 0; border-radius: 14px; text-align: center; border: 1px solid var(--line); font-size: .78rem; font-weight: 700; color: var(--ink-soft); background: rgba(255,255,255,0.02); transition: all 0.2s ease; }
.day-pill .num { display: block; font-family: var(--font-display); font-size: 1.15rem; margin-top: 2px; color: #fff; }
.day-pill.active, .day-pill:hover { background: var(--gold); color: #0D0E12; border-color: var(--gold); }
.day-pill.active .num, .day-pill:hover .num { color: #0D0E12; }

.slots-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; }
.slot-btn { padding: 11px 0; border-radius: 10px; border: 1px solid var(--line); background: rgba(255,255,255,0.02); color: var(--ink); font-weight: 700; font-size: .85rem; transition: all 0.2s ease; }
.slot-btn.active, .slot-btn:hover { background: var(--gold); color: #0D0E12; border-color: var(--gold); }
.slots-empty { font-size: .85rem; color: var(--ink-soft); padding: 18px 0; text-align: center; }

.booking-form { margin-top: 24px; display: none; flex-direction: column; gap: 12px; }
.booking-form.open { display: flex; }
.booking-form input, .booking-form textarea {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  font-family: inherit;
  font-size: .9rem;
  transition: all 0.2s ease;
}
.booking-form input:focus, .booking-form textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255,255,255,0.07);
}
.booking-form input::placeholder, .booking-form textarea::placeholder { color: rgba(255,255,255,0.3); }

.hours-list { list-style: none; padding: 0; margin: 0; font-size: .9rem; }
.hours-list li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink-soft); }
.hours-list li.today { font-weight: 800; color: var(--gold); }
.hours-list li.today span { color: var(--gold); }

/* --- AUTHPANEL (LOGIN, SIGNUP) --- */
.auth-wrap {
  max-width: 460px;
  margin: 80px auto;
  background: rgba(17, 24, 39, 0.8);
  border: 1px solid var(--line-light);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: #fff;
}
.auth-wrap h1 { font-size: 1.8rem; color: #fff; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: .85rem; font-weight: 700; margin-bottom: 6px; color: var(--gold-light); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  font-family: inherit;
  font-size: .92rem;
  transition: all 0.2s ease;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255,255,255,0.07);
}
.field select option {
  background: #0F172A;
  color: #fff;
}
.helptext { font-size: .76rem; color: var(--ink-soft); margin-top: 6px; display: block; line-height: 1.4; }
.errorlist { color: #EF4444; font-size: .8rem; list-style: none; padding: 0; margin: 6px 0 0; }
.alert { padding: 14px 18px; border-radius: 12px; margin-bottom: 20px; font-size: .88rem; }
.alert-error { background: rgba(239, 68, 68, 0.15); border: 1px solid rgba(239, 68, 68, 0.3); color: #FCA5A5; }
.alert-success { background: rgba(16, 185, 129, 0.15); border: 1px solid rgba(16, 185, 129, 0.3); color: #A7F3D0; }

/* --- TABLEAU DE BORD ESPACE PRO --- */
.dash-shell { display: grid; grid-template-columns: 240px 1fr; gap: 0; min-height: 80vh; }
@media (max-width: 800px) { .dash-shell { grid-template-columns: 1fr; } }
.dash-side { background: rgba(17, 24, 39, 0.85); border-right: 1px solid var(--line); padding: 30px 20px; }
.dash-side a { display: block; padding: 12px 14px; border-radius: 10px; font-weight: 600; font-size: .9rem; margin-bottom: 6px; color: var(--ink-soft); }
.dash-side a:hover, .dash-side a.active { background: rgba(255,255,255,0.04); color: #fff; }
.dash-main { padding: 40px; background: transparent; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-bottom: 36px; }
.stat-card { background: rgba(255, 255, 255, 0.02); border: 1px solid var(--line); border-radius: 16px; padding: 22px; }
.stat-card .num { font-family: var(--font-display); font-size: 2.2rem; color: var(--gold); font-weight: 600; }
.stat-card .label { font-size: .8rem; color: var(--ink-soft); margin-top: 4px; }
table.appt-table { width: 100%; border-collapse: collapse; background: rgba(255, 255, 255, 0.02); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
table.appt-table th, table.appt-table td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--line); font-size: .88rem; color: var(--ink-soft); }
table.appt-table td strong { color: #fff; }
table.appt-table th { background: rgba(255, 255, 255, 0.04); font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: #fff; }
.badge { padding: 5px 12px; border-radius: 999px; font-size: .72rem; font-weight: 800; display: inline-block; }
.badge-pending { background: rgba(245, 158, 11, 0.15); color: #FBBF24; border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-confirmed { background: rgba(16, 185, 129, 0.15); color: #34D399; border: 1px solid rgba(16, 185, 129, 0.3); }
.badge-cancelled { background: rgba(239, 68, 68, 0.15); color: #F87171; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-done { background: rgba(59, 130, 246, 0.15); color: #60A5FA; border: 1px solid rgba(59, 130, 246, 0.3); }
.status-form select { padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line); background: rgba(255,255,255,0.05); color: #fff; font-size: .78rem; outline: none; }
.status-form select option { background: #0F172A; }

@media (max-width: 640px) {
  .slots-grid { grid-template-columns: repeat(2, 1fr); }
  .salon-identity { flex-direction: column; align-items: flex-start; gap: 14px; margin-top: -60px; }
  .salon-logo { width: 90px; height: 90px; }
}
