/* ============================================================
   BledyEasy - Platform Stylesheet
   A platform for Moroccan expatriates (MRE)
   ============================================================
   Table of Contents:
   1.  CSS Variables
   2.  Reset & Base
   3.  Typography
   4.  Navigation
   5.  Hero Sections
   6.  Container & Grid
   7.  Cards
   8.  Buttons
   9.  Forms
   10. Badges & Pills
   11. Tables
   12. Pagination
   13. Alerts
   14. Modals
   15. Auth Pages
   16. Dashboard
   17. Blog
   18. Forum
   19. Service Cards
   20. Marketplace
   21. Covoiturage
   22. Fret / Freight
   23. Footer
   24. Utility Classes
   25. Animations & Keyframes
   26. Responsive Breakpoints
   ============================================================ */


/* ============================================================
   1. CSS Variables
   ============================================================ */

:root {
  /* Moroccan palette */
  --emerald: #006233;
  --emerald-light: #1B7A4E;
  --emerald-dark: #004D28;
  --gold: #D4A853;
  --gold-light: #E8C97A;
  --terracotta: #C75B39;
  --sand: #F5EDE3;
  --cream: #FEFCF9;
  --night: #1A1A2E;
  --night-light: #2D2D44;

  /* Neutrals */
  --gray-100: #F7F7F8;
  --gray-200: #E8E8EC;
  --gray-300: #D1D1D9;
  --gray-400: #9999A8;
  --gray-500: #6B6B7B;
  --gray-600: #4A4A5A;
  --white: #FFFFFF;

  /* Semantic */
  --danger: #DC3545;
  --success: #28A745;
  --warning: #FFC107;
  --info: #17A2B8;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 3rem;

  /* Radius */
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-pill: 100px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(26, 26, 46, 0.06);
  --shadow: 0 4px 12px rgba(26, 26, 46, 0.08);
  --shadow-md: 0 8px 24px rgba(26, 26, 46, 0.1);
  --shadow-lg: 0 16px 48px rgba(26, 26, 46, 0.12);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition: 0.25s ease;
  --transition-slow: 0.35s ease;

  /* Z-index scale */
  --z-dropdown: 100;
  --z-nav: 200;
  --z-modal-backdrop: 300;
  --z-modal: 400;
}


/* ============================================================
   2. Reset & Base
   ============================================================ */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--night);
  background-color: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--emerald);
  text-decoration: none;
  transition: color var(--transition-fast), text-decoration var(--transition-fast);
}

a:hover {
  text-decoration: underline;
  color: var(--emerald-dark);
}

ul,
ol {
  list-style: none;
}

button {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

::selection {
  background-color: var(--emerald);
  color: var(--white);
}


/* ============================================================
   3. Typography
   ============================================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  line-height: 1.25;
  color: var(--night);
  margin-bottom: 0.5em;
}

h1 {
  font-size: 2.5rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2rem;
  letter-spacing: -0.015em;
}

h3 {
  font-size: 1.5rem;
}

h4 {
  font-size: 1.25rem;
}

h5 {
  font-size: 1.1rem;
}

h6 {
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

p {
  margin-bottom: 1rem;
}

p:last-child {
  margin-bottom: 0;
}

.lead {
  font-size: 1.2rem;
  line-height: 1.7;
  color: var(--gray-500);
}

small,
.text-sm {
  font-size: 0.875rem;
}

.text-xs {
  font-size: 0.75rem;
}

.text-lg {
  font-size: 1.125rem;
}

strong {
  font-weight: 600;
}

hr {
  border: none;
  border-top: 1px solid var(--gray-200);
  margin: var(--space-4) 0;
}


/* ============================================================
   4. Navigation
   ============================================================ */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  background: var(--white);
  box-shadow: 0 1px 0 rgba(26, 26, 46, 0.06), 0 2px 8px rgba(26, 26, 46, 0.03);
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav-logo {
  font-family: 'Syne', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--emerald);
  text-decoration: none;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.nav-logo:hover {
  color: var(--emerald);
  text-decoration: none;
}

.nav-logo span {
  color: var(--gold);
}

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

.nav-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-600);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background var(--transition-fast);
  position: relative;
}

.nav-links a:hover {
  color: var(--emerald);
  background: rgba(0, 98, 51, 0.04);
  text-decoration: none;
}

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

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0.9rem;
  right: 0.9rem;
  height: 2px;
  background: var(--emerald);
  border-radius: 2px;
}

/* User menu area */
.nav-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.nav-user .btn {
  font-size: 0.875rem;
  padding: 0.45rem 1.1rem;
}

.nav-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--sand);
  border: 2px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--emerald);
  cursor: pointer;
  transition: border-color var(--transition-fast);
  overflow: hidden;
}

.nav-avatar:hover {
  border-color: var(--emerald);
}

.nav-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* User dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 200px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 0.5rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity var(--transition-fast), transform var(--transition-fast), visibility var(--transition-fast);
  z-index: var(--z-dropdown);
}

.nav-dropdown.open .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 1rem;
  font-size: 0.875rem;
  color: var(--gray-600);
  transition: background var(--transition-fast), color var(--transition-fast);
}

.nav-dropdown-menu a:hover {
  background: var(--gray-100);
  color: var(--night);
  text-decoration: none;
}

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

/* Mobile hamburger — checkbox hack, no JS */
.nav-toggle {
  display: none;
}

.nav-toggle-label {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 28px;
  height: 28px;
  cursor: pointer;
}

.nav-toggle-label span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--night);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(2) {
  opacity: 0;
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Reserve space for fixed nav */
body {
  padding-top: 72px;
}


/* ============================================================
   5. Hero Sections
   ============================================================ */

.hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(135deg, var(--emerald) 0%, var(--emerald-dark) 100%);
  color: var(--white);
  padding: var(--space-5) var(--space-4);
  overflow: hidden;
}

/* Geometric pattern overlay */
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0.06;
  background-image:
    radial-gradient(circle at 20% 50%, var(--white) 1px, transparent 1px),
    radial-gradient(circle at 80% 20%, var(--white) 1.5px, transparent 1.5px),
    radial-gradient(circle at 60% 80%, var(--white) 1px, transparent 1px);
  background-size: 60px 60px, 80px 80px, 50px 50px;
  pointer-events: none;
}

/* Decorative diamond shape */
.hero::after {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 240px;
  height: 240px;
  border: 2px solid rgba(255, 255, 255, 0.08);
  transform: rotate(45deg);
  border-radius: 16px;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.hero h1 {
  color: var(--white);
  font-size: 3rem;
  margin-bottom: 0.75rem;
}

.hero p {
  font-size: 1.15rem;
  opacity: 0.9;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.hero .btn {
  margin-top: 0.5rem;
}

/* Small hero for interior pages */
.hero-small {
  position: relative;
  min-height: 25vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--emerald) 0%, var(--emerald-dark) 100%);
  color: var(--white);
  padding: var(--space-5) var(--space-4);
  overflow: hidden;
}

.hero-small::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0.05;
  background-image:
    radial-gradient(circle at 30% 40%, var(--white) 1px, transparent 1px),
    radial-gradient(circle at 70% 60%, var(--white) 1px, transparent 1px);
  background-size: 50px 50px, 70px 70px;
  pointer-events: none;
}

.hero-small h1 {
  color: var(--white);
  font-size: 2.25rem;
  margin-bottom: 0.25rem;
}

.hero-small p {
  opacity: 0.85;
  font-size: 1.05rem;
}

/* Breadcrumbs inside small hero */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
  opacity: 0.75;
}

.breadcrumb a {
  color: var(--white);
  text-decoration: none;
  opacity: 0.8;
  transition: opacity var(--transition-fast);
}

.breadcrumb a:hover {
  opacity: 1;
  text-decoration: underline;
}

.breadcrumb .separator {
  opacity: 0.5;
  font-size: 0.75rem;
}

.breadcrumb .current {
  opacity: 1;
  font-weight: 500;
}


/* ============================================================
   6. Container & Grid
   ============================================================ */

.container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.container-narrow {
  max-width: 800px;
}

.container-wide {
  max-width: 1440px;
}

/* CSS Grid layouts */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

/* Flex utilities */
.flex {
  display: flex;
}

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

.flex-col {
  flex-direction: column;
}

.items-center {
  align-items: center;
}

.items-start {
  align-items: flex-start;
}

.items-end {
  align-items: flex-end;
}

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

.justify-between {
  justify-content: space-between;
}

.justify-end {
  justify-content: flex-end;
}

.gap-1 {
  gap: var(--space-1);
}

.gap-2 {
  gap: var(--space-2);
}

.gap-3 {
  gap: var(--space-3);
}

.gap-4 {
  gap: var(--space-4);
}

.gap-5 {
  gap: var(--space-5);
}


/* ============================================================
   7. Cards
   ============================================================ */

.card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.card-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--gray-200);
  font-weight: 600;
}

.card-body {
  padding: 1.5rem;
}

.card-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--gray-200);
  background: var(--gray-100);
}

.card-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

/* Card: no hover lift */
.card-flat {
  box-shadow: none;
}

.card-flat:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
}

/* Card: Service variant */
.card-service {
  text-align: center;
  padding: 2rem 1.5rem;
  border: 1px solid var(--gray-200);
}

.card-service .card-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(0, 98, 51, 0.08) 0%, rgba(0, 98, 51, 0.03) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--emerald);
}

.card-service h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.card-service p {
  font-size: 0.9rem;
  color: var(--gray-500);
  margin-bottom: 1rem;
}

.card-service .price {
  font-family: 'Syne', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 1rem;
}

.card-service .price small {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--gray-400);
}

/* Card: Listing variant (marketplace) */
.card-listing {
  display: flex;
  flex-direction: column;
}

.card-listing .card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-listing .listing-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 1rem;
  font-size: 0.8rem;
  color: var(--gray-400);
}

.card-listing .listing-meta .city {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.card-listing .listing-budget {
  font-family: 'Syne', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--emerald);
  margin-bottom: 0.5rem;
}

/* Card: Trip variant (covoiturage) */
.card-trip {
  padding: 1.25rem 1.5rem;
}

.card-trip .trip-route {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.card-trip .trip-city {
  font-weight: 600;
  font-size: 1rem;
}

.card-trip .trip-arrow {
  color: var(--gold);
  font-size: 1.2rem;
  flex-shrink: 0;
}

.card-trip .trip-details {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.85rem;
  color: var(--gray-500);
}

.card-trip .trip-price {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--emerald);
}

/* Card status badges */
.card-status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.card-status::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.card-status-active::before {
  background: var(--success);
}

.card-status-active {
  color: var(--success);
}

.card-status-pending::before {
  background: var(--warning);
}

.card-status-pending {
  color: #B8860B;
}

.card-status-completed::before {
  background: var(--gray-400);
}

.card-status-completed {
  color: var(--gray-400);
}

.card-status-cancelled::before {
  background: var(--danger);
}

.card-status-cancelled {
  color: var(--danger);
}


/* ============================================================
   8. Buttons
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.5rem;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.4;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition:
    background var(--transition-fast),
    color var(--transition-fast),
    border-color var(--transition-fast),
    box-shadow var(--transition-fast),
    transform var(--transition-fast);
  white-space: nowrap;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn:disabled,
.btn.disabled {
  opacity: 0.5;
  pointer-events: none;
}

/* Primary */
.btn-primary {
  background: var(--emerald);
  color: var(--white);
  border-color: var(--emerald);
  box-shadow: 0 2px 4px rgba(0, 98, 51, 0.2);
}

.btn-primary:hover {
  background: var(--emerald-dark);
  border-color: var(--emerald-dark);
  box-shadow: 0 4px 12px rgba(0, 98, 51, 0.3);
  color: var(--white);
}

/* Secondary */
.btn-secondary {
  background: var(--white);
  color: var(--emerald);
  border-color: var(--emerald);
}

.btn-secondary:hover {
  background: var(--emerald);
  color: var(--white);
}

/* Gold */
.btn-gold {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--night);
  border-color: var(--gold);
  box-shadow: 0 2px 4px rgba(212, 168, 83, 0.25);
}

.btn-gold:hover {
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 100%);
  box-shadow: 0 4px 12px rgba(212, 168, 83, 0.35);
  color: var(--night);
}

/* Danger */
.btn-danger {
  background: var(--danger);
  color: var(--white);
  border-color: var(--danger);
}

.btn-danger:hover {
  background: #c82333;
  border-color: #c82333;
  color: var(--white);
}

/* Ghost / Text button */
.btn-ghost {
  background: transparent;
  color: var(--gray-600);
  border-color: transparent;
}

.btn-ghost:hover {
  background: var(--gray-100);
  color: var(--night);
}

/* Sizes */
.btn-sm {
  padding: 0.4rem 0.9rem;
  font-size: 0.8rem;
}

.btn-lg {
  padding: 0.85rem 2rem;
  font-size: 1rem;
}

/* Icon button */
.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-sm);
}

.btn-icon.btn-sm {
  width: 32px;
  height: 32px;
}

.btn-icon.btn-lg {
  width: 48px;
  height: 48px;
}

/* Button group */
.btn-group {
  display: inline-flex;
  gap: 0.5rem;
}


/* ============================================================
   9. Forms
   ============================================================ */

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--gray-600);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.7rem 1rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--night);
  background: var(--sand);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
  outline: none;
}

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

.form-control:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(0, 98, 51, 0.1);
  background: var(--white);
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
  line-height: 1.6;
}

/* Custom select */
.form-select {
  display: block;
  width: 100%;
  padding: 0.7rem 2.5rem 0.7rem 1rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--night);
  background-color: var(--sand);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236B6B7B' d='M1.41 0L6 4.58 10.59 0 12 1.41l-6 6-6-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  cursor: pointer;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-select:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(0, 98, 51, 0.1);
  background-color: var(--white);
}

/* Multi-column form row */
.form-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

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

/* Validation states */
.form-control.is-invalid,
.form-select.is-invalid {
  border-color: var(--danger);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.12);
}

.invalid-feedback {
  font-size: 0.8rem;
  color: var(--danger);
  margin-top: 0.3rem;
}

/* Helper text */
.form-hint {
  font-size: 0.8rem;
  color: var(--gray-400);
  margin-top: 0.3rem;
}

/* Checkbox and radio */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.form-check input[type="checkbox"],
.form-check input[type="radio"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--emerald);
  flex-shrink: 0;
}

.form-check label {
  font-size: 0.9rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
  color: var(--night);
  cursor: pointer;
}

/* Search input */
.form-search {
  position: relative;
}

.form-search .form-control {
  padding-left: 2.75rem;
}

.form-search .search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-400);
  pointer-events: none;
  font-size: 0.9rem;
}


/* ============================================================
   10. Badges & Pills
   ============================================================ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.badge-emerald {
  background: rgba(0, 98, 51, 0.1);
  color: var(--emerald);
}

.badge-gold {
  background: rgba(212, 168, 83, 0.15);
  color: #9A7C30;
}

.badge-terracotta {
  background: rgba(199, 91, 57, 0.1);
  color: var(--terracotta);
}

.badge-gray {
  background: var(--gray-200);
  color: var(--gray-600);
}

.badge-danger {
  background: rgba(220, 53, 69, 0.1);
  color: var(--danger);
}

.badge-success {
  background: rgba(40, 167, 69, 0.1);
  color: var(--success);
}

.badge-info {
  background: rgba(23, 162, 184, 0.1);
  color: var(--info);
}

.badge-warning {
  background: rgba(255, 193, 7, 0.15);
  color: #8A6D00;
}

/* Category badges — slightly larger for forum/marketplace */
.badge-category {
  padding: 0.3rem 0.8rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Status badge — used on orders, listings */
.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.7rem;
  font-size: 0.72rem;
  font-weight: 600;
}

.badge-status::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}


/* ============================================================
   11. Tables
   ============================================================ */

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.table th {
  text-align: left;
  padding: 0.85rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-500);
  border-bottom: 2px solid var(--gray-200);
  white-space: nowrap;
}

.table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--gray-200);
  vertical-align: middle;
}

.table tbody tr:nth-child(even) {
  background: var(--sand);
}

.table tbody tr:hover {
  background: rgba(0, 98, 51, 0.02);
}

.table-compact th,
.table-compact td {
  padding: 0.6rem 0.75rem;
}


/* ============================================================
   12. Pagination
   ============================================================ */

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 1.5rem 0;
}

.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--gray-600);
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast);
}

.pagination a:hover {
  background: var(--gray-100);
  border-color: var(--gray-300);
  color: var(--night);
  text-decoration: none;
}

.pagination .active {
  background: var(--emerald);
  color: var(--white);
  border-color: var(--emerald);
}

.pagination .disabled {
  opacity: 0.4;
  pointer-events: none;
}

.pagination .ellipsis {
  border: none;
  background: none;
  color: var(--gray-400);
  min-width: auto;
  padding: 0 0.25rem;
}


/* ============================================================
   13. Alerts
   ============================================================ */

.alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  border-left: 4px solid transparent;
}

.alert-icon {
  font-size: 1.15rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.alert-content {
  flex: 1;
}

.alert-dismiss {
  flex-shrink: 0;
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  opacity: 0.5;
  transition: opacity var(--transition-fast);
  line-height: 1;
  padding: 0;
  color: inherit;
}

.alert-dismiss:hover {
  opacity: 1;
}

.alert-success {
  background: rgba(40, 167, 69, 0.08);
  border-left-color: var(--success);
  color: #1E5631;
}

.alert-danger {
  background: rgba(220, 53, 69, 0.08);
  border-left-color: var(--danger);
  color: #721C24;
}

.alert-warning {
  background: rgba(255, 193, 7, 0.1);
  border-left-color: var(--warning);
  color: #664D03;
}

.alert-info {
  background: rgba(23, 162, 184, 0.08);
  border-left-color: var(--info);
  color: #0C5460;
}


/* ============================================================
   14. Modals
   ============================================================ */

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 46, 0.5);
  z-index: var(--z-modal-backdrop);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), visibility var(--transition);
  backdrop-filter: blur(2px);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 90%;
  max-width: 560px;
  max-height: 85vh;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: var(--z-modal);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal.active {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.modal-lg {
  max-width: 780px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--gray-200);
}

.modal-header h3 {
  margin-bottom: 0;
  font-size: 1.15rem;
}

.modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  color: var(--gray-400);
  background: none;
  border: none;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.modal-close:hover {
  background: var(--gray-100);
  color: var(--night);
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--gray-200);
  background: var(--gray-100);
}


/* ============================================================
   15. Auth Pages
   ============================================================ */

.auth-page {
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--sand);
  padding: 2rem 1rem;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2.5rem 2rem;
}

.auth-logo {
  text-align: center;
  margin-bottom: 2rem;
}

.auth-logo a {
  font-family: 'Syne', sans-serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--emerald);
  text-decoration: none;
}

.auth-logo a span {
  color: var(--gold);
}

.auth-title {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}

.auth-subtitle {
  text-align: center;
  color: var(--gray-500);
  font-size: 0.9rem;
  margin-bottom: 1.75rem;
}

.auth-card .form-group {
  margin-bottom: 1rem;
}

.auth-card .btn {
  width: 100%;
  padding: 0.75rem;
  font-size: 0.95rem;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.5rem 0;
  color: var(--gray-400);
  font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-200);
}

/* Social login buttons */
.auth-social {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.65rem 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--gray-600);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast);
}

.btn-social:hover {
  background: var(--gray-100);
  border-color: var(--gray-300);
}

.btn-social img {
  width: 20px;
  height: 20px;
}

.auth-toggle {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.875rem;
  color: var(--gray-500);
}

.auth-toggle a {
  font-weight: 600;
  color: var(--emerald);
}

.auth-forgot {
  text-align: right;
  margin-bottom: 1rem;
}

.auth-forgot a {
  font-size: 0.825rem;
  color: var(--gray-500);
}

.auth-forgot a:hover {
  color: var(--emerald);
}


/* ============================================================
   16. Dashboard
   ============================================================ */

.dashboard {
  display: flex;
  min-height: calc(100vh - 72px);
}

/* Sidebar */
.dashboard-sidebar {
  width: 260px;
  background: var(--white);
  border-right: 1px solid var(--gray-200);
  padding: 1.5rem 0;
  flex-shrink: 0;
  position: sticky;
  top: 72px;
  height: calc(100vh - 72px);
  overflow-y: auto;
}

.dashboard-sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-600);
  text-decoration: none;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.dashboard-sidebar-nav a:hover {
  color: var(--emerald);
  background: rgba(0, 98, 51, 0.04);
  text-decoration: none;
}

.dashboard-sidebar-nav a.active {
  color: var(--emerald);
  background: rgba(0, 98, 51, 0.06);
  font-weight: 600;
  border-right: 3px solid var(--emerald);
}

.dashboard-sidebar-nav .nav-section-title {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-400);
  padding: 1.25rem 1.5rem 0.4rem;
}

/* Main content area */
.dashboard-main {
  flex: 1;
  padding: 2rem;
  min-width: 0;
}

.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.dashboard-header h1 {
  font-size: 1.75rem;
  margin-bottom: 0;
}

/* Stat cards */
.stat-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
}

.stat-card .stat-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-500);
  margin-bottom: 0.5rem;
}

.stat-card .stat-value {
  font-family: 'Syne', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--night);
  line-height: 1.2;
}

.stat-card .stat-change {
  font-size: 0.8rem;
  margin-top: 0.5rem;
}

.stat-card .stat-change.positive {
  color: var(--success);
}

.stat-card .stat-change.negative {
  color: var(--danger);
}

/* Activity feed */
.activity-feed {
  list-style: none;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--gray-200);
}

.activity-item:last-child {
  border-bottom: none;
}

.activity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--emerald);
  flex-shrink: 0;
  margin-top: 6px;
}

.activity-content {
  flex: 1;
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.5;
}

.activity-time {
  font-size: 0.75rem;
  color: var(--gray-400);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Profile section */
.profile-section {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 2rem;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--gray-200);
}

.profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--sand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Syne', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--emerald);
  flex-shrink: 0;
  overflow: hidden;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-name {
  font-family: 'Syne', sans-serif;
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.profile-meta {
  font-size: 0.85rem;
  color: var(--gray-500);
}


/* ============================================================
   17. Blog
   ============================================================ */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.blog-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}

.blog-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.blog-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.blog-card-body {
  padding: 1.25rem 1.5rem;
}

.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.78rem;
  color: var(--gray-400);
  margin-bottom: 0.6rem;
}

.blog-card-body h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  line-height: 1.35;
}

.blog-card-body h3 a {
  color: var(--night);
  text-decoration: none;
}

.blog-card-body h3 a:hover {
  color: var(--emerald);
  text-decoration: none;
}

.blog-card-excerpt {
  font-size: 0.875rem;
  color: var(--gray-500);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Article reading view */
.article {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.article-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.article-header h1 {
  font-size: 2.5rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--gray-500);
}

.article-author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.article-author img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.article-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--night-light);
}

.article-content p {
  margin-bottom: 1.5rem;
}

.article-content h2 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  font-size: 1.6rem;
}

.article-content h3 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.article-content img {
  width: 100%;
  border-radius: var(--radius-sm);
  margin: 2rem 0;
}

.article-content figcaption {
  text-align: center;
  font-size: 0.85rem;
  color: var(--gray-500);
  margin-top: -1.25rem;
  margin-bottom: 2rem;
}

.article-content blockquote {
  border-left: 4px solid var(--emerald);
  padding: 1rem 1.5rem;
  margin: 2rem 0;
  background: rgba(0, 98, 51, 0.03);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--gray-600);
}

.article-content blockquote p:last-child {
  margin-bottom: 0;
}

.article-content ul,
.article-content ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.article-content ul {
  list-style: disc;
}

.article-content ol {
  list-style: decimal;
}

.article-content li {
  margin-bottom: 0.5rem;
}

.article-content code {
  font-family: 'JetBrains Mono', monospace;
  background: var(--sand);
  padding: 0.15em 0.4em;
  border-radius: 3px;
  font-size: 0.88em;
}

.article-content pre {
  background: var(--night);
  color: var(--gray-200);
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-sm);
  overflow-x: auto;
  margin: 2rem 0;
}

.article-content pre code {
  background: none;
  padding: 0;
  color: inherit;
}


/* ============================================================
   18. Forum
   ============================================================ */

.forum-list {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
}

.forum-post {
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--gray-200);
  transition: background var(--transition-fast);
}

.forum-post:last-child {
  border-bottom: none;
}

.forum-post:hover {
  background: var(--gray-100);
}

.forum-post-title {
  font-weight: 600;
  font-size: 0.95rem;
}

.forum-post-title a {
  color: var(--night);
  text-decoration: none;
}

.forum-post-title a:hover {
  color: var(--emerald);
}

.forum-post-excerpt {
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-top: 0.2rem;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.forum-post-replies {
  font-size: 0.8rem;
  color: var(--gray-400);
  text-align: center;
  min-width: 60px;
}

.forum-post-replies strong {
  display: block;
  font-size: 1rem;
  color: var(--night);
}

.forum-post-date {
  font-size: 0.78rem;
  color: var(--gray-400);
  min-width: 80px;
  text-align: right;
}

/* Forum detail page */
.forum-detail {
  max-width: 900px;
  margin: 0 auto;
}

.forum-question {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2rem;
}

.forum-question h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.forum-question-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-bottom: 1.25rem;
}

.forum-question-content {
  font-size: 0.95rem;
  line-height: 1.75;
}

/* Replies */
.forum-replies-header {
  font-size: 1rem;
  margin-bottom: 1rem;
  color: var(--gray-600);
}

.reply {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1rem;
  margin-left: 1.5rem;
}

.reply-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.reply-author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.reply-author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--sand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--emerald);
  flex-shrink: 0;
}

.reply-date {
  font-size: 0.78rem;
  color: var(--gray-400);
}

.reply-content {
  font-size: 0.9rem;
  line-height: 1.7;
}

/* Best answer */
.reply.best-answer {
  border-color: var(--gold);
  border-width: 2px;
  background: rgba(212, 168, 83, 0.03);
}

.reply.best-answer::before {
  content: 'Meilleure reponse';
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold);
  background: rgba(212, 168, 83, 0.1);
  padding: 0.15rem 0.6rem;
  border-radius: var(--radius-pill);
  margin-bottom: 0.75rem;
}


/* ============================================================
   19. Service Cards
   ============================================================ */

.service-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.service-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition);
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.service-card .service-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1.25rem;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(0, 98, 51, 0.1) 0%, rgba(0, 98, 51, 0.04) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  color: var(--emerald);
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.service-card .service-description {
  font-size: 0.88rem;
  color: var(--gray-500);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.service-card .service-price {
  font-family: 'Syne', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 0.25rem;
}

.service-card .service-price-note {
  font-size: 0.8rem;
  color: var(--gray-400);
  margin-bottom: 1.25rem;
}

.service-card .btn {
  width: 100%;
}


/* ============================================================
   20. Marketplace
   ============================================================ */

.listing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.listing-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition), box-shadow var(--transition);
}

.listing-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.listing-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.listing-card-title {
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.35;
  flex: 1;
}

.listing-card-title a {
  color: var(--night);
  text-decoration: none;
}

.listing-card-title a:hover {
  color: var(--emerald);
}

.listing-card-body {
  font-size: 0.85rem;
  color: var(--gray-500);
  line-height: 1.55;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.listing-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--gray-200);
  font-size: 0.8rem;
}

.listing-card-city {
  color: var(--gray-500);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.listing-card-budget {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  color: var(--emerald);
}

.listing-card-date {
  color: var(--gray-400);
  font-size: 0.75rem;
}

/* Urgency indicators */
.urgency {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
}

.urgency-urgent {
  background: rgba(199, 91, 57, 0.1);
  color: var(--terracotta);
}

.urgency-normal {
  background: var(--gray-200);
  color: var(--gray-600);
}

.urgency-flexible {
  background: rgba(0, 98, 51, 0.08);
  color: var(--emerald);
}


/* ============================================================
   21. Covoiturage (Rideshare)
   ============================================================ */

.trip-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.trip-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: transform var(--transition), box-shadow var(--transition);
}

.trip-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

/* Route display */
.trip-route {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.trip-point {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
}

.trip-point-city {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--night);
}

.trip-point-detail {
  font-size: 0.78rem;
  color: var(--gray-400);
  margin-top: 0.15rem;
}

/* Arrow visualization */
.trip-route-arrow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  flex-shrink: 0;
  padding: 0 0.25rem;
}

.trip-route-line {
  width: 48px;
  height: 2px;
  background: var(--gold);
  position: relative;
}

.trip-route-line::after {
  content: '';
  position: absolute;
  right: -2px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid var(--gold);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.trip-route-duration {
  font-size: 0.7rem;
  color: var(--gray-400);
  white-space: nowrap;
}

/* Trip details row */
.trip-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--gray-200);
}

.trip-date {
  font-size: 0.85rem;
  color: var(--gray-600);
  font-weight: 500;
}

.trip-price {
  font-family: 'Syne', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--emerald);
}

/* Seat availability dots */
.trip-seats {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.trip-seats-label {
  font-size: 0.78rem;
  color: var(--gray-500);
  margin-right: 0.25rem;
}

.trip-seat-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--emerald);
}

.trip-seat-dot.taken {
  background: var(--gray-300);
}

.trip-seat-dot.available {
  background: var(--emerald);
}


/* ============================================================
   22. Fret / Freight
   ============================================================ */

.shipment-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.shipment-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: transform var(--transition), box-shadow var(--transition);
}

.shipment-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.shipment-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.shipment-card-title {
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.35;
}

.shipment-card-title a {
  color: var(--night);
  text-decoration: none;
}

.shipment-card-title a:hover {
  color: var(--emerald);
}

.shipment-route {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 0.75rem;
}

.shipment-route .route-from {
  font-weight: 600;
}

.shipment-route .route-arrow {
  color: var(--gold);
}

.shipment-route .route-to {
  font-weight: 600;
}

.shipment-specs {
  display: flex;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--gray-500);
  margin-bottom: 0.75rem;
}

.shipment-specs span {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.shipment-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.75rem;
  border-top: 1px solid var(--gray-200);
  font-size: 0.8rem;
}

.shipment-date {
  color: var(--gray-400);
}

/* Quote form */
.quote-form {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 2rem;
}

.quote-form h3 {
  margin-bottom: 1.5rem;
}

.quote-form .form-row {
  margin-bottom: 0;
}

.quote-form .btn {
  margin-top: 1rem;
}


/* ============================================================
   23. Footer
   ============================================================ */

.footer {
  background: var(--emerald-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 4rem 0 0;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer-about h4 {
  font-family: 'Syne', sans-serif;
  color: var(--white);
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
}

.footer-about h4 span {
  color: var(--gold);
}

.footer-about p {
  font-size: 0.88rem;
  line-height: 1.65;
  opacity: 0.75;
}

.footer-links h5 {
  font-family: 'Syne', sans-serif;
  color: var(--white);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.875rem;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--gold-light);
  text-decoration: none;
}

.footer-contact h5 {
  font-family: 'Syne', sans-serif;
  color: var(--white);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.875rem;
  margin-bottom: 0.6rem;
  opacity: 0.75;
}

/* Social links */
.footer-social {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.25rem;
}

.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.footer-social a:hover {
  background: var(--gold);
  color: var(--night);
  text-decoration: none;
}

/* Footer bottom bar */
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.25rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  opacity: 0.6;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.6);
}

.footer-bottom a:hover {
  color: var(--gold-light);
}


/* ============================================================
   24. Utility Classes
   ============================================================ */

/* Text alignment */
.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.text-left {
  text-align: left;
}

/* Text colors */
.text-emerald {
  color: var(--emerald);
}

.text-gold {
  color: var(--gold);
}

.text-terracotta {
  color: var(--terracotta);
}

.text-muted {
  color: var(--gray-500);
}

.text-danger {
  color: var(--danger);
}

.text-success {
  color: var(--success);
}

.text-white {
  color: var(--white);
}

/* Font weight */
.font-bold {
  font-weight: 700;
}

.font-semibold {
  font-weight: 600;
}

.font-normal {
  font-weight: 400;
}

/* Margin top */
.mt-1 {
  margin-top: var(--space-1);
}

.mt-2 {
  margin-top: var(--space-2);
}

.mt-3 {
  margin-top: var(--space-3);
}

.mt-4 {
  margin-top: var(--space-4);
}

.mt-5 {
  margin-top: var(--space-5);
}

/* Margin bottom */
.mb-1 {
  margin-bottom: var(--space-1);
}

.mb-2 {
  margin-bottom: var(--space-2);
}

.mb-3 {
  margin-bottom: var(--space-3);
}

.mb-4 {
  margin-bottom: var(--space-4);
}

.mb-5 {
  margin-bottom: var(--space-5);
}

/* Padding y-axis */
.py-1 {
  padding-top: var(--space-1);
  padding-bottom: var(--space-1);
}

.py-2 {
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}

.py-3 {
  padding-top: var(--space-3);
  padding-bottom: var(--space-3);
}

.py-4 {
  padding-top: var(--space-4);
  padding-bottom: var(--space-4);
}

.py-5 {
  padding-top: var(--space-5);
  padding-bottom: var(--space-5);
}

/* Padding x-axis */
.px-1 {
  padding-left: var(--space-1);
  padding-right: var(--space-1);
}

.px-2 {
  padding-left: var(--space-2);
  padding-right: var(--space-2);
}

.px-3 {
  padding-left: var(--space-3);
  padding-right: var(--space-3);
}

.px-4 {
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

/* Visibility */
.hidden {
  display: none !important;
}

.visible-mobile {
  display: none !important;
}

.visible-desktop {
  display: block !important;
}

/* Overflow */
.overflow-hidden {
  overflow: hidden;
}

/* Width */
.w-full {
  width: 100%;
}

/* Positioning */
.relative {
  position: relative;
}

/* Border */
.border-top {
  border-top: 1px solid var(--gray-200);
}

.border-bottom {
  border-bottom: 1px solid var(--gray-200);
}

/* Rounded */
.rounded {
  border-radius: var(--radius);
}

.rounded-full {
  border-radius: 50%;
}

/* Skeleton loading */
.skeleton {
  background: linear-gradient(
    90deg,
    var(--gray-200) 0%,
    var(--gray-100) 40%,
    var(--gray-200) 80%
  );
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
  border-radius: var(--radius-sm);
  min-height: 1rem;
}

.skeleton-text {
  height: 0.9rem;
  margin-bottom: 0.5rem;
  border-radius: 4px;
}

.skeleton-text:last-child {
  width: 60%;
}

.skeleton-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

.skeleton-card {
  height: 200px;
  border-radius: var(--radius);
}

@keyframes skeleton-pulse {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Truncate */
.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Screen reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}


/* ============================================================
   25. Animations & Keyframes
   ============================================================ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Animation utility classes */
.animate-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-fade {
  animation: fadeIn var(--transition-slow) ease both;
}

.animate-slide-up {
  animation: slideUp var(--transition-slow) ease both;
}

.animate-pulse {
  animation: pulse 2s ease-in-out infinite;
}

/* Staggered animation delays */
.animate-delay-1 {
  animation-delay: 0.1s;
}

.animate-delay-2 {
  animation-delay: 0.2s;
}

.animate-delay-3 {
  animation-delay: 0.3s;
}

.animate-delay-4 {
  animation-delay: 0.4s;
}

/* Spinner */
.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid var(--gray-200);
  border-top-color: var(--emerald);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.spinner-sm {
  width: 16px;
  height: 16px;
  border-width: 2px;
}

.spinner-lg {
  width: 40px;
  height: 40px;
  border-width: 4px;
}

/* Transition utilities */
.transition-all {
  transition: all var(--transition);
}

.transition-colors {
  transition: color var(--transition-fast), background-color var(--transition-fast), border-color var(--transition-fast);
}


/* ============================================================
   26. Responsive Breakpoints
   ============================================================ */

/* Small devices (max 480px) */
@media (max-width: 480px) {
  h1 {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  h3 {
    font-size: 1.25rem;
  }

  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

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

  .hero p {
    font-size: 1rem;
  }

  .auth-card {
    padding: 1.75rem 1.25rem;
  }

  .form-row,
  .form-row-3 {
    grid-template-columns: 1fr;
  }

  .listing-card-footer {
    flex-wrap: wrap;
  }

  .article-header h1 {
    font-size: 1.75rem;
  }
}

/* Tablets and below (max 768px) */
@media (max-width: 768px) {
  /* Navigation mobile collapse */
  .nav-toggle-label {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    background: var(--white);
    padding: 1rem;
    gap: 0;
    transform: translateX(100%);
    transition: transform var(--transition);
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
  }

  .nav-toggle:checked ~ .nav-links {
    transform: translateX(0);
  }

  .nav-links a {
    padding: 0.85rem 1rem;
    font-size: 1rem;
    border-radius: var(--radius-sm);
  }

  .nav-links a.active::after {
    display: none;
  }

  .nav-links a.active {
    background: rgba(0, 98, 51, 0.06);
  }

  .nav-user {
    display: none;
  }

  .nav-toggle:checked ~ .nav-links .nav-user-mobile {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
    margin-top: 0.5rem;
    border-top: 1px solid var(--gray-200);
  }

  /* Grids collapse */
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  /* Blog grid */
  .blog-grid {
    grid-template-columns: 1fr;
  }

  /* Service list */
  .service-list {
    grid-template-columns: 1fr;
  }

  /* Listings */
  .listing-grid {
    grid-template-columns: 1fr;
  }

  /* Trips */
  .trip-grid {
    grid-template-columns: 1fr;
  }

  /* Shipments */
  .shipment-grid {
    grid-template-columns: 1fr;
  }

  /* Dashboard sidebar to top tabs */
  .dashboard {
    flex-direction: column;
  }

  .dashboard-sidebar {
    width: 100%;
    height: auto;
    position: static;
    border-right: none;
    border-bottom: 1px solid var(--gray-200);
    padding: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
  }

  .dashboard-sidebar-nav {
    display: flex;
    white-space: nowrap;
    padding: 0 1rem;
  }

  .dashboard-sidebar-nav .nav-section-title {
    display: none;
  }

  .dashboard-sidebar-nav a {
    padding: 0.75rem 1rem;
    font-size: 0.82rem;
    border-right: none;
    border-bottom: 2px solid transparent;
    flex-shrink: 0;
  }

  .dashboard-sidebar-nav a.active {
    border-right: none;
    border-bottom: 2px solid var(--emerald);
    background: transparent;
  }

  .dashboard-main {
    padding: 1.25rem 1rem;
  }

  .dashboard-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  /* Forum */
  .forum-post {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .forum-post-replies,
  .forum-post-date {
    text-align: left;
  }

  .reply {
    margin-left: 0;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }

  /* Hero */
  .hero {
    min-height: 50vh;
    padding: 3rem 1.25rem;
  }

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

  .hero-small {
    min-height: 20vh;
  }

  .hero-small h1 {
    font-size: 1.75rem;
  }

  /* Profile */
  .profile-header {
    flex-direction: column;
    text-align: center;
  }

  /* Visibility */
  .visible-mobile {
    display: block !important;
  }

  .visible-desktop {
    display: none !important;
  }

  /* Table */
  .table th,
  .table td {
    padding: 0.65rem 0.6rem;
    font-size: 0.82rem;
  }

  /* Stat cards stack better */
  .stat-card .stat-value {
    font-size: 1.5rem;
  }
}

/* Medium devices (max 1024px) */
@media (max-width: 1024px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

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

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Large devices (min 1200px) */
@media (min-width: 1200px) {
  .container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .animate-in {
    opacity: 1;
    transform: none;
  }
}

/* Print styles */
@media print {
  .nav,
  .footer,
  .btn,
  .modal,
  .modal-backdrop,
  .dashboard-sidebar {
    display: none !important;
  }

  body {
    padding-top: 0;
    background: white;
    color: black;
    font-size: 12pt;
  }

  .container {
    max-width: 100%;
    padding: 0;
  }

  a {
    color: black;
    text-decoration: underline;
  }

  .card,
  .alert {
    border: 1px solid #ccc;
    box-shadow: none;
  }
}
