/* =============================================================================
   Speedi-Solutions — Feuille de style principale avec Thème Sombre & Mobile
   assets/css/style.css
   ============================================================================= */

/* ---------------------------------------------------------------------------
   1. Variables CSS (Mode Clair & Mode Sombre)
   --------------------------------------------------------------------------- */
:root {
  --color-bg:        #f8fafc;
  --color-surface:   #ffffff;
  --color-surface-hover: #f1f5f9;
  --color-primary:   #0f172a;   /* bleu nuit ardoise pro */
  --color-primary-light: #1e293b;
  --color-accent:    #2563eb;
  --color-accent-hover: #1d4ed8;
  --color-text:      #0f172a;
  --color-text-secondary: #475569;
  --color-muted:     #64748b;
  --color-border:    #e2e8f0;
  --color-border-subtle: #f1f5f9;
  --color-danger:    #ef4444;
  --color-success:   #10b981;
  --color-warning:   #f59e0b;
  --color-info:      #06b6d4;

  --radius-sm:       6px;
  --radius:          10px;
  --radius-lg:       14px;
  --shadow-sm:       0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow:          0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg:       0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --transition:      0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --font-sans:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono:       'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  --max-width:       1180px;

  --nav-bg:          #0f172a;
  --nav-text:        #f8fafc;
}

/* Thème Sombre */
[data-theme="dark"] {
  --color-bg:        #090d16;
  --color-surface:   #111827;
  --color-surface-hover: #1f2937;
  --color-primary:   #38bdf8;
  --color-primary-light: #0284c7;
  --color-accent:    #3b82f6;
  --color-accent-hover: #60a5fa;
  --color-text:      #f3f4f6;
  --color-text-secondary: #9ca3af;
  --color-muted:     #94a3b8;
  --color-border:    #1f2937;
  --color-border-subtle: #1a2234;

  --shadow-sm:       0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow:          0 4px 6px -1px rgba(0, 0, 0, 0.4);
  --shadow-lg:       0 10px 25px -5px rgba(0, 0, 0, 0.6);

  --nav-bg:          #0a0f1d;
  --nav-text:        #f3f4f6;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 15px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color var(--transition), color var(--transition);
  -webkit-font-smoothing: antialiased;
}

/* ---------------------------------------------------------------------------
   2. Liens & Typographie
   --------------------------------------------------------------------------- */
a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition), opacity var(--transition);
}

a:hover {
  color: var(--color-accent-hover);
  text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--color-text);
  font-weight: 700;
  line-height: 1.25;
}

p {
  color: var(--color-text-secondary);
}

/* ---------------------------------------------------------------------------
   3. Conteneur & Layout
   --------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

main {
  flex: 1;
  padding-block: 2rem;
}

/* ---------------------------------------------------------------------------
   4. Barre de Navigation Moderne & Pro
   --------------------------------------------------------------------------- */
nav {
  background-color: var(--nav-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(8px);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding-inline: 1.5rem;
  max-width: var(--max-width);
  margin-inline: auto;
}

.nav-brand-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.nav-logo i {
  color: var(--color-accent);
}

.nav-mobile-actions {
  display: none;
  align-items: center;
  gap: 0.5rem;
}

/* Bouton Burger Mobile */
.nav-mobile-toggle {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.35rem;
  cursor: pointer;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-theme-btn {
  margin-left: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.78);
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all var(--transition);
}

.nav-links a:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.nav-links a.active {
  background-color: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  font-weight: 600;
}

.nav-separator {
  width: 1px;
  height: 22px;
  background: rgba(255, 255, 255, 0.16);
  margin-inline: 0.35rem;
}

/* Dropdown Menu (Compte / Espace) */
.nav-dropdown {
  position: relative;
  display: inline-block;
}

.nav-dropdown-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff !important;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-family: inherit;
  transition: all var(--transition);
}

.nav-dropdown-btn:hover {
  background: rgba(255, 255, 255, 0.16);
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.4rem);
  right: 0;
  min-width: 220px;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 0.5rem 0;
  z-index: 1200;
}

.nav-dropdown-menu.show {
  display: block;
  animation: fadeIn 0.15s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.nav-dropdown-menu a {
  display: flex !important;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1.15rem !important;
  color: var(--color-text) !important;
  font-size: 0.9rem !important;
  font-weight: 500;
  border-radius: 0 !important;
  transition: background-color var(--transition);
}

.nav-dropdown-menu a:hover {
  background-color: var(--color-surface-hover) !important;
  color: var(--color-accent) !important;
}

.nav-dropdown-menu hr {
  border: 0;
  border-top: 1px solid var(--color-border);
  margin: 0.4rem 0;
}

/* Theme Toggle Button */
.theme-toggle-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  margin-left: 0.35rem;
}

.theme-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: rotate(15deg);
}

/* ---------------------------------------------------------------------------
   5. Cartes Professionnelles (Cards)
   --------------------------------------------------------------------------- */
.card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.75rem;
  margin-bottom: 1.75rem;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-lg);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--color-border);
}

.card-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 1.25rem;
}

[data-theme="dark"] .card-icon-wrap {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
}

/* Grilles */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* KPI Grid */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.kpi-card {
  padding: 1.5rem;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.kpi-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.kpi-value {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--color-text);
  line-height: 1.1;
}

.kpi-sub {
  font-size: 0.85rem;
  color: var(--color-muted);
  margin-top: 0.4rem;
}

/* ---------------------------------------------------------------------------
   6. Boutons Modernes
   --------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  line-height: 1.4;
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--color-accent);
  color: #ffffff !important;
  box-shadow: 0 2px 4px rgba(37, 99, 235, 0.25);
}

.btn-primary:hover {
  background-color: var(--color-accent-hover);
  box-shadow: 0 4px 8px rgba(37, 99, 235, 0.35);
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-text) !important;
  border-color: var(--color-border);
}

.btn-secondary:hover {
  background-color: var(--color-surface-hover);
  border-color: var(--color-muted);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-accent) !important;
  border-color: var(--color-accent);
}

.btn-outline:hover {
  background-color: var(--color-accent);
  color: #ffffff !important;
}

.btn-danger {
  background-color: var(--color-danger);
  color: #ffffff !important;
}

.btn-danger:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.btn-block {
  width: 100%;
}

/* ---------------------------------------------------------------------------
   7. Formulaires
   --------------------------------------------------------------------------- */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label, label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.4rem;
}

.required {
  color: var(--color-danger);
  margin-left: 0.2rem;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.65rem 0.9rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--color-text);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-control:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.form-control::placeholder {
  color: var(--color-muted);
}

textarea.form-control {
  resize: vertical;
  min-height: 110px;
}

select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  padding-right: 2.2rem;
}

.radio-group {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.4rem;
}

.radio-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-weight: normal;
}

/* ---------------------------------------------------------------------------
   8. Tableaux Professionnels
   --------------------------------------------------------------------------- */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  background-color: var(--color-surface);
  text-align: left;
}

.table thead {
  background-color: var(--color-surface-hover);
  color: var(--color-muted);
}

.table thead th {
  padding: 0.85rem 1rem;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--color-border);
}

.table tbody tr {
  border-bottom: 1px solid var(--color-border);
  transition: background-color var(--transition);
}

.table tbody tr:hover {
  background-color: var(--color-surface-hover);
}

.table td {
  padding: 0.85rem 1rem;
  vertical-align: middle;
  color: var(--color-text);
}

/* ---------------------------------------------------------------------------
   9. Badges de statut
   --------------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
}

.badge-actif, .badge-payee, .badge-accepte, .badge-success {
  background-color: rgba(16, 185, 129, 0.12);
  color: #10b981;
}

.badge-en_attente, .badge-warning {
  background-color: rgba(245, 158, 11, 0.12);
  color: #d97706;
}

[data-theme="dark"] .badge-en_attente, [data-theme="dark"] .badge-warning {
  color: #fbbf24;
}

.badge-suspendu {
  background-color: rgba(234, 88, 12, 0.12);
  color: #ea580c;
}

.badge-resilie, .badge-annulee, .badge-refuse, .badge-danger {
  background-color: rgba(239, 68, 68, 0.12);
  color: #ef4444;
}

.badge-ouvert {
  background-color: rgba(37, 99, 235, 0.12);
  color: #2563eb;
}

.badge-brouillon, .badge-ferme, .badge-secondary {
  background-color: rgba(100, 116, 139, 0.12);
  color: var(--color-muted);
}

/* ---------------------------------------------------------------------------
   10. Alertes Flash
   --------------------------------------------------------------------------- */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.5rem;
  font-size: 0.92rem;
  border: 1px solid transparent;
}

.alert-success {
  background-color: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.25);
  color: #10b981;
}

.alert-error {
  background-color: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.25);
  color: #ef4444;
}

.alert-warning {
  background-color: rgba(245, 158, 11, 0.1);
  border-color: rgba(245, 158, 11, 0.25);
  color: #f59e0b;
}

.alert-info {
  background-color: rgba(37, 99, 235, 0.1);
  border-color: rgba(37, 99, 235, 0.25);
  color: #3b82f6;
}

/* ---------------------------------------------------------------------------
   11. Hero & Sections Vitrine
   --------------------------------------------------------------------------- */
.hero {
  padding: 4.5rem 0 3.5rem;
  text-align: center;
}

.hero h1 {
  font-size: 2.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
  line-height: 1.15;
}

.hero-subtitle {
  font-size: 1.15rem;
  max-width: 720px;
  margin: 0 auto 2rem;
  color: var(--color-text-secondary);
}

.hero-cta {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.section {
  padding: 3.5rem 0;
}

.section-title {
  font-size: 1.85rem;
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  text-align: center;
  color: var(--color-muted);
  max-width: 600px;
  margin: 0 auto 2.5rem;
}

/* Offres Cards */
.card-offre {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-top: 3px solid var(--color-accent);
}

.offre-nom {
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
}

.offre-prix {
  margin-bottom: 1.25rem;
}

.prix-montant {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--color-text);
}

.prix-cycle {
  font-size: 0.85rem;
  color: var(--color-muted);
}

.specs-pre {
  font-family: var(--font-sans);
  font-size: 0.88rem;
  color: var(--color-text-secondary);
  background: var(--color-surface-hover);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  margin-top: 0.5rem;
  white-space: pre-wrap;
  border: 1px solid var(--color-border);
}

/* ---------------------------------------------------------------------------
   12. Auth Form Wrapper
   --------------------------------------------------------------------------- */
.auth-wrapper {
  max-width: 440px;
  margin: 2.5rem auto;
}

.auth-wrapper-wide {
  max-width: 620px;
}

.auth-header {
  text-align: center;
  margin-bottom: 1.75rem;
}

.auth-logo {
  font-size: 2.25rem;
  color: var(--color-accent);
  margin-bottom: 0.75rem;
}

.auth-footer {
  text-align: center;
  margin-top: 1.75rem;
  font-size: 0.9rem;
  border-top: 1px solid var(--color-border);
  padding-top: 1.25rem;
}

/* ---------------------------------------------------------------------------
   13. Footer
   --------------------------------------------------------------------------- */
footer {
  background-color: var(--nav-bg);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.65);
  padding-block: 2rem;
  margin-top: auto;
  font-size: 0.88rem;
}

.footer-inner {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

footer a {
  color: rgba(255, 255, 255, 0.75);
}

footer a:hover {
  color: #ffffff;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

/* ---------------------------------------------------------------------------
   14. Mobile Responsive & Adaptation Écran
   --------------------------------------------------------------------------- */
@media (max-width: 868px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }

  .nav-mobile-actions {
    display: flex;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.5rem;
  }

  .nav-links.show {
    display: flex;
  }

  .nav-links a {
    padding: 0.65rem 0.85rem;
    font-size: 0.95rem;
  }

  .nav-links .btn {
    width: 100%;
    justify-content: center;
  }

  .nav-links .nav-separator {
    display: none;
  }

  .nav-links .theme-toggle-btn {
    display: none;
  }

  .nav-dropdown {
    width: 100%;
  }

  .nav-dropdown-btn {
    width: 100%;
    justify-content: space-between;
  }

  .nav-dropdown-menu {
    position: static;
    box-shadow: none;
    border: 1px solid var(--color-border);
    margin-top: 0.5rem;
  }

  .nav-inner {
    flex-wrap: wrap;
  }

  .hero h1 {
    font-size: 2.1rem;
  }

  .hero-cta {
    flex-direction: column;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }

  .footer-links {
    justify-content: center;
  }
}

/* ---------------------------------------------------------------------------
   15. Checkout & Panier Perfectionnés (Desktop & Mobile)
   --------------------------------------------------------------------------- */
.checkout-container {
  width: 100%;
  max-width: 1100px;
  margin-inline: auto;
}

.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 390px;
  gap: 2rem;
  align-items: start;
}

.checkout-header-banner {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.75rem;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.checkout-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.checkout-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 1rem;
  margin-bottom: 1.25rem;
}

.checkout-summary-card {
  position: sticky;
  top: 85px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-top: 4px solid var(--color-accent);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.checkout-summary-table {
  background: var(--color-surface-hover);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.checkout-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.checkout-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.checkout-label {
  color: var(--color-text-secondary);
  font-size: 0.83rem;
  flex: 1;
  line-height: 1.35;
}

.checkout-val {
  font-weight: 700;
  color: var(--color-text);
  text-align: right;
  font-size: 0.88rem;
  white-space: nowrap;
}

.checkout-totals {
  border-top: 1px solid var(--color-border);
  padding-top: 1rem;
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.checkout-total-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.92rem;
}

.checkout-grand-total {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding-top: 0.75rem;
  margin-top: 0.5rem;
  border-top: 2px solid var(--color-border);
}

.checkout-grand-total-label {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}

.checkout-grand-total-amount {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--color-accent);
  line-height: 1.1;
  letter-spacing: -0.5px;
}

.checkout-stripe-btn {
  background: #635bff;
  color: #ffffff !important;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.95rem 1.25rem;
  font-size: 1.05rem;
  font-weight: 700;
  width: 100%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  transition: transform 0.15s, background-color 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 14px rgba(99, 91, 255, 0.28);
}

.checkout-stripe-btn:hover {
  background: #5348ec;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(99, 91, 255, 0.4);
}

@media (max-width: 900px) {
  .checkout-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .checkout-summary-card {
    position: static;
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 768px) {
  .checkout-container {
    padding: 0.75rem 0.25rem;
  }

  .checkout-header-banner {
    padding: 1rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .checkout-header-banner h1 {
    font-size: 1.35rem !important;
  }

  .checkout-card {
    padding: 1.15rem 0.75rem;
    border-radius: var(--radius-sm);
  }

  .checkout-summary-card {
    padding: 1.15rem 0.75rem;
    border-radius: var(--radius-sm);
  }

  .checkout-grand-total-amount {
    font-size: 1.6rem;
  }

  /* Form control anti-zoom iOS */
  .form-control, select.form-control {
    font-size: 16px !important;
  }
}

/* Groupes d'inputs avec addon / suffixe de prix (ex: [ 0 ] x 1,00 €) */
.input-group {
  display: flex;
  align-items: stretch;
  width: 100%;
}

.input-group .form-control {
  border-top-right-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
  flex: 1;
}

.input-group-addon {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  background: var(--color-surface-hover);
  border: 1px solid var(--color-border);
  border-left: none;
  border-top-right-radius: var(--radius-sm);
  border-bottom-right-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  white-space: nowrap;
}

/* ---------------------------------------------------------------------------
   16. Mode Impression (@media print)
   --------------------------------------------------------------------------- */
@media print {
  nav, footer, .btn, .no-print, .alert, .category-nav, .theme-toggle-btn {
    display: none !important;
  }

  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 10pt;
  }

  .document-print {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
  }

  table {
    border-collapse: collapse !important;
  }

  th, td {
    color: #000000 !important;
  }
}
