/* TOP Limo Service — espace client & administration */
:root {
  --c-primary: #3d5818;
  --c-secondary: #8a7a1c;
  --c-dark: #16220b;
  --c-ink: #1f2a1a;
  --c-cream: #f8f6ef;
  --c-line: #e6e2d4;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Source Serif 4', Georgia, serif;
  background: var(--c-cream); color: var(--c-ink);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: 'Playfair Display', Georgia, serif; margin: 0; font-weight: 700; }
a { color: var(--c-primary); text-decoration: none; }
a:hover { color: var(--c-secondary); }
.mono, input, select, textarea, button, .ui { font-family: 'Montserrat', sans-serif; }

/* --- barre supérieure --- */
.topnav { background: var(--c-dark); color: #fff; }
.topnav-in { max-width: 1240px; margin: 0 auto; padding: 14px 26px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand .w1 { font-family: 'Playfair Display', Georgia, serif; font-style: italic; font-weight: 700; font-size: 19px; color: #fff; line-height: 1; }
.brand .w2 { font-family: 'Montserrat', sans-serif; font-size: 9px; letter-spacing: .24em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.navlinks { display: flex; align-items: center; gap: 20px; }
.navlinks a, .navlinks button {
  font-family: 'Montserrat', sans-serif; font-size: 12px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase; color: rgba(255,255,255,.75);
  background: none; border: none; cursor: pointer; padding: 0;
}
.navlinks a:hover, .navlinks button:hover { color: var(--c-secondary); }
.navlinks a.on { color: var(--c-secondary); }

.wrap { max-width: 1240px; margin: 0 auto; padding: 34px 26px 70px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.page-head h1 { font-size: 30px; }
.page-head p { margin: 7px 0 0; color: #6b6752; font-size: 15px; }

/* --- cartes & KPI --- */
.card { background: #fff; border: 1px solid var(--c-line); padding: 24px; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 16px; margin-bottom: 26px; }
.kpi { background: #fff; border: 1px solid var(--c-line); padding: 20px 22px; }
.kpi .lab { font-family: 'Montserrat', sans-serif; font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #8a8672; }
.kpi .val { font-family: 'Playfair Display', Georgia, serif; font-size: 32px; color: var(--c-primary); margin-top: 8px; line-height: 1; }
.kpi .sub { font-family: 'Montserrat', sans-serif; font-size: 11.5px; color: #a5a08c; margin-top: 7px; }
.kpi.gold .val { color: var(--c-secondary); }

/* --- onglets & filtres --- */
.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.tab {
  font-family: 'Montserrat', sans-serif; font-size: 11.5px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase; padding: 10px 15px;
  border: 1.5px solid var(--c-line); background: #fff; color: #55523f; cursor: pointer;
}
.tab.on { background: var(--c-primary); border-color: var(--c-primary); color: #fff; }
.tab .n { opacity: .7; margin-left: 5px; }

/* --- tableaux --- */
.tbl-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--c-line); }
table { width: 100%; border-collapse: collapse; min-width: 900px; }
th {
  font-family: 'Montserrat', sans-serif; font-size: 10px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: #8a8672;
  text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--c-line); white-space: nowrap;
}
td { padding: 14px 16px; border-bottom: 1px solid #f2efe6; font-size: 14px; vertical-align: top; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #fcfbf7; }
td .ref { font-family: 'Montserrat', sans-serif; font-size: 11.5px; color: #a5a08c; }
td .name { font-weight: 600; }
td .muted { color: #8a8672; font-size: 12.5px; }
td .amt { font-family: 'Playfair Display', Georgia, serif; font-size: 17px; color: var(--c-primary); }

/* --- badges de statut --- */
.st { font-family: 'Montserrat', sans-serif; font-size: 9.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; padding: 5px 9px; border-radius: 3px; white-space: nowrap; display: inline-block; }
.st-pending   { background: #fdf3d4; color: #7a6412; }
.st-confirmed { background: #e3ecf7; color: #1f4b7a; }
.st-paid      { background: #e6f0da; color: #35521a; }
.st-completed { background: #e8e5f5; color: #4a3d7a; }
.st-refused   { background: #f7e3e3; color: #8a2b2b; }
.st-cancelled { background: #eeece5; color: #6b6752; }
.st-abandoned { background: #eeece5; color: #8a8672; }

/* --- boutons --- */
.btn {
  font-family: 'Montserrat', sans-serif; font-size: 11.5px; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase; padding: 11px 18px;
  border-radius: 2px; border: 1.5px solid transparent; cursor: pointer; display: inline-block;
}
.btn-p { background: var(--c-primary); color: #fff; }
.btn-p:hover { background: var(--c-secondary); color: #fff; }
.btn-g { background: var(--c-secondary); color: #fff; }
.btn-o { background: #fff; border-color: var(--c-line); color: #55523f; }
.btn-o:hover { border-color: var(--c-secondary); color: var(--c-primary); }
.btn-d { background: #fff; border-color: #e4c9c9; color: #8a2b2b; }
.btn-sm { padding: 8px 12px; font-size: 10.5px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* --- formulaires --- */
.fld { display: flex; flex-direction: column; gap: 7px; margin-bottom: 15px; }
.fld label { font-family: 'Montserrat', sans-serif; font-size: 10.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #8a8672; }
.fld input, .fld select, .fld textarea {
  font-family: 'Montserrat', sans-serif; font-size: 14px; padding: 12px 14px;
  border: 1.5px solid #e0dcce; background: #fcfbf7; color: var(--c-ink); width: 100%; border-radius: 2px;
}
.fld input:focus, .fld select:focus, .fld textarea:focus { outline: none; border-color: var(--c-secondary); background: #fff; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }

/* --- connexion --- */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: linear-gradient(165deg, #233313, #0c1206); color: #fff; padding: 56px 48px; display: flex; flex-direction: column; justify-content: center; }
.auth-side h2 { font-size: 34px; margin-bottom: 16px; }
.auth-side p { color: rgba(255,255,255,.7); font-size: 16px; line-height: 1.75; margin: 0; }
.auth-side ul { list-style: none; padding: 0; margin: 26px 0 0; display: flex; flex-direction: column; gap: 12px; }
.auth-side li { display: flex; gap: 10px; font-family: 'Montserrat', sans-serif; font-size: 13.5px; color: rgba(255,255,255,.8); }
.auth-side li svg { width: 16px; height: 16px; color: var(--c-secondary); flex-shrink: 0; margin-top: 2px; }
.auth-main { display: flex; align-items: center; justify-content: center; padding: 48px 32px; }
.auth-box { width: 100%; max-width: 400px; }
.auth-box h1 { font-size: 27px; margin-bottom: 8px; }
.auth-box .lead { color: #6b6752; font-size: 15px; margin: 0 0 26px; }
.switch { text-align: center; margin-top: 20px; font-family: 'Montserrat', sans-serif; font-size: 13px; color: #6b6752; }

/* --- messages --- */
.msg { padding: 13px 16px; font-family: 'Montserrat', sans-serif; font-size: 13px; line-height: 1.6; margin-bottom: 18px; border-radius: 2px; display: none; }
.msg.on { display: block; }
.msg-err { background: #f9e9e9; color: #8a2b2b; border: 1px solid #e4c9c9; }
.msg-ok  { background: #e9f2df; color: #35521a; border: 1px solid #cfe0bb; }
.msg-info{ background: #f4f1e4; color: #6b6752; border: 1px solid var(--c-line); }

/* --- rapport --- */
.bars { display: flex; flex-direction: column; gap: 12px; margin-top: 6px; }
.bar-row { display: grid; grid-template-columns: 92px 1fr 90px; gap: 14px; align-items: center; }
.bar-row .m { font-family: 'Montserrat', sans-serif; font-size: 11.5px; color: #8a8672; }
.bar-track { display: block; background: #f0ede2; height: 22px; position: relative; overflow: hidden; }
.bar-fill { display: block; background: linear-gradient(90deg, var(--c-primary), var(--c-secondary)); height: 100%; min-width: 2px; }
.bar-row .v { font-family: 'Playfair Display', Georgia, serif; font-size: 16px; color: var(--c-primary); text-align: right; }

.empty { text-align: center; padding: 60px 20px; color: #8a8672; }
.empty h3 { font-size: 20px; margin-bottom: 8px; color: var(--c-ink); }
.empty p { margin: 0; font-size: 15px; }

.setup { background: #fdf3d4; border: 1px solid #e8d59a; padding: 18px 20px; margin-bottom: 24px; font-family: 'Montserrat', sans-serif; font-size: 13px; line-height: 1.7; color: #6b5410; }
.setup code { background: rgba(0,0,0,.06); padding: 2px 6px; font-size: 12px; }

@media (max-width: 860px) {
  .kpis { grid-template-columns: 1fr 1fr; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .grid2 { grid-template-columns: 1fr; }
  .wrap { padding: 24px 18px 60px; }
  .topnav-in { padding: 12px 18px; }
  .navlinks { gap: 14px; }
}
