:root {
  --bg: #0f172a;
  --surface: #1e293b;
  --surface-alt: #273449;
  --text: #f1f5f9;
  --text-muted: #94a3b8;
  --accent: #22c55e;
  --danger: #ef4444;
  --border: #334155;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding-bottom: 72px;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

.page {
  max-width: 480px;
  margin: 0 auto;
  padding: 20px 16px;
}

h1 {
  font-size: 1.4rem;
  margin: 0 0 16px;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.empty {
  color: var(--text-muted);
  text-align: center;
  margin-top: 40px;
}

.recharge-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.recharge-list a {
  display: block;
  background: var(--surface);
  border-radius: 12px;
  padding: 14px 16px;
  text-decoration: none;
  color: var(--text);
  border: 1px solid var(--border);
}

.recharge-date {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.recharge-main {
  display: flex;
  justify-content: space-between;
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 4px;
}

.recharge-lieu {
  margin-top: 4px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.btn-fab {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent);
  color: #052e16;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  line-height: 1;
}

form.recharge-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}

label {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 10px;
}

input, select {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 12px;
  font-size: 1rem;
}

.form-row {
  display: flex;
  gap: 12px;
}

.form-row > div {
  flex: 1;
}

button, .btn-secondary, .btn-danger {
  margin-top: 18px;
  padding: 14px;
  border-radius: 10px;
  border: none;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  display: block;
}

button[type="submit"] {
  background: var(--accent);
  color: #052e16;
}

.btn-secondary {
  background: var(--surface-alt);
  color: var(--text);
}

.btn-danger {
  background: transparent;
  color: var(--danger);
  border: 1px solid var(--danger);
  width: 100%;
}

.error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid var(--danger);
  color: #fecaca;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.hint {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-top: 4px;
}

.stats-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.stat-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  text-align: center;
}

.stat-tile span {
  display: block;
  font-size: 1.3rem;
  font-weight: 700;
}

.stat-tile label {
  margin: 0;
  font-size: 0.75rem;
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  background: var(--surface);
  border-top: 1px solid var(--border);
}

.bottom-nav a {
  flex: 1;
  text-align: center;
  padding: 14px 8px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
}

.bottom-nav a.active {
  color: var(--accent);
  font-weight: 600;
}

.nav-logout {
  flex: 0.7 !important;
}
