/* CampusHub Botswana — Main Stylesheet */
/* Mobile-first, modern, clean */

:root {
  --primary:       #2563eb;
  --primary-dark:  #1d4ed8;
  --primary-light: #dbeafe;
  --accent:        #f59e0b;
  --success:       #16a34a;
  --warning:       #d97706;
  --danger:        #dc2626;
  --text:          #111827;
  --text-muted:    #6b7280;
  --border:        #e5e7eb;
  --bg:            #f9fafb;
  --white:         #ffffff;
  --card-shadow:   0 1px 3px rgba(0,0,0,.07), 0 4px 12px rgba(0,0,0,.05);
  --card-shadow-hover: 0 4px 16px rgba(0,0,0,.12);
  --radius:        10px;
  --radius-sm:     6px;
  --radius-lg:     16px;
  --transition:    .2s ease;
  --font:          'Inter', system-ui, -apple-system, sans-serif;
  --nav-h:         64px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { list-style: none; }

/* =============================================
   TYPOGRAPHY
   ============================================= */
h1 { font-size: clamp(1.5rem, 4vw, 2.25rem); font-weight: 800; line-height: 1.2; }
h2 { font-size: clamp(1.25rem, 3vw, 1.75rem); font-weight: 700; line-height: 1.3; }
h3 { font-size: 1.125rem; font-weight: 600; }
h4 { font-size: 1rem; font-weight: 600; }
p  { color: var(--text); }
.text-muted  { color: var(--text-muted); font-size: .875rem; }
.text-link   { color: var(--primary); font-size: .875rem; }
.text-danger { color: var(--danger); }
.gradient-text { background: linear-gradient(135deg, #2563eb, #7c3aed); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* =============================================
   LAYOUT
   ============================================= */
.container    { max-width: 1200px; margin: 0 auto; padding: 0 1rem; }
.container-sm { max-width: 800px;  margin: 0 auto; padding: 0 1rem; }
.main-content { min-height: calc(100vh - var(--nav-h)); padding-top: var(--nav-h); }

/* =============================================
   BUTTONS
   ============================================= */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .55rem 1.25rem; border-radius: var(--radius-sm); font-size: .875rem;
  font-weight: 500; cursor: pointer; border: 1.5px solid transparent;
  transition: all var(--transition); white-space: nowrap; text-decoration: none;
  font-family: var(--font);
}
.btn:hover { text-decoration: none; }
.btn-primary    { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-outline    { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary-light); }
.btn-outline-white { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-outline-white:hover { background: rgba(255,255,255,.1); }
.btn-ghost      { background: transparent; color: var(--text-muted); border-color: var(--border); }
.btn-ghost:hover { background: var(--bg); color: var(--text); }
.btn-white      { background: #fff; color: var(--primary); border-color: #fff; }
.btn-white:hover { background: var(--primary-light); }
.btn-success    { background: var(--success); color: #fff; border-color: var(--success); }
.btn-warning    { background: var(--warning); color: #fff; border-color: var(--warning); }
.btn-danger     { background: var(--danger);  color: #fff; border-color: var(--danger); }
.btn-sm  { padding: .35rem .9rem;  font-size: .8125rem; }
.btn-lg  { padding: .75rem 1.75rem; font-size: 1rem; font-weight: 600; }
.btn-xs  { padding: .2rem .6rem;   font-size: .75rem; }
.btn-block { width: 100%; justify-content: center; display: flex; }
.mt-2 { margin-top: .5rem; }
.ml-auto { margin-left: auto; }
.p-3 { padding: 1rem; }

/* =============================================
   FORMS
   ============================================= */
.form-group   { margin-bottom: 1rem; }
.form-row     { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-control {
  width: 100%; padding: .625rem .875rem; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); font-size: .9rem; font-family: var(--font);
  background: #fff; color: var(--text); transition: border-color var(--transition);
}
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.form-control::placeholder { color: var(--text-muted); }
.form-control-sm { padding: .4rem .75rem; font-size: .8125rem; }
.form-hint    { font-size: .78rem; color: var(--text-muted); margin-top: .25rem; display: block; }
.form-check   { display: flex; align-items: center; gap: .5rem; }
.form-check input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--primary); }
.form-check label { font-size: .875rem; cursor: pointer; }
label         { display: block; font-size: .875rem; font-weight: 500; margin-bottom: .35rem; color: var(--text); }
.label-link   { float: right; font-weight: 400; color: var(--primary); }
.required     { color: var(--danger); }
.input-password { position: relative; }
.input-password .form-control { padding-right: 2.75rem; }
.toggle-password { position: absolute; right: .75rem; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-muted); padding: 0; }
.char-counter { font-size: .75rem; color: var(--text-muted); text-align: right; display: block; margin-top: .2rem; }
.char-counter.over-limit { color: var(--danger); }
.input-error { border-color: var(--danger) !important; }
.form-submit-row { display: flex; align-items: center; justify-content: flex-end; gap: 1rem; margin-top: 1.5rem; }
.checkbox-group { display: flex; flex-wrap: wrap; gap: .75rem; }
.checkbox-label { display: flex; align-items: center; gap: .4rem; font-size: .875rem; cursor: pointer; }

/* =============================================
   ALERTS
   ============================================= */
.alert { padding: .875rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1rem; font-size: .875rem; display: flex; align-items: flex-start; gap: .5rem; }
.alert-success { background: #dcfce7; color: #166534; border-left: 4px solid var(--success); }
.alert-error   { background: #fee2e2; color: #991b1b; border-left: 4px solid var(--danger); }
.alert-warning { background: #fef9c3; color: #854d0e; border-left: 4px solid var(--accent); }
.alert-info    { background: #dbeafe; color: #1e40af; border-left: 4px solid var(--primary); }
.error-list    { padding-left: 1rem; list-style: disc; }
.error-list li { margin-bottom: .2rem; }

/* =============================================
   BADGES
   ============================================= */
.badge { display: inline-flex; align-items: center; padding: .2rem .55rem; border-radius: 100px; font-size: .73rem; font-weight: 600; }
.badge-verified { background: #dcfce7; color: #166534; }
.badge-warning  { background: #fef9c3; color: #854d0e; }
.badge-info     { background: #dbeafe; color: #1e40af; }
.badge-success  { background: #dcfce7; color: #166534; }
.badge-danger   { background: #fee2e2; color: #991b1b; }
.badge-featured { position: absolute; top: .5rem; left: .5rem; background: var(--accent); color: #fff; padding: .2rem .55rem; border-radius: 100px; font-size: .7rem; font-weight: 700; z-index: 2; }
.badge-category { display: inline-flex; align-items: center; padding: .2rem .55rem; background: rgba(255,255,255,.9); color: var(--text); border-radius: 100px; font-size: .72rem; font-weight: 600; }
.verified-dot { color: var(--success); font-weight: 700; margin-left: .2rem; font-size: .8rem; }
.status-badge { display: inline-flex; align-items: center; padding: .2rem .55rem; border-radius: 100px; font-size: .73rem; font-weight: 600; text-transform: capitalize; }
.status-active  { background: #dcfce7; color: #166534; }
.status-pending { background: #fef9c3; color: #854d0e; }
.status-sold    { background: #f3f4f6; color: var(--text-muted); }
.status-removed { background: #fee2e2; color: #991b1b; }
.status-suspended { background: #fee2e2; color: #991b1b; }

/* =============================================
   NAVBAR
   ============================================= */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h); background: rgba(255,255,255,.95);
  backdrop-filter: blur(12px); border-bottom: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.navbar.scrolled { box-shadow: 0 2px 16px rgba(0,0,0,.08); }
.navbar .container { display: flex; align-items: center; justify-content: space-between; height: 100%; }
.logo { display: flex; align-items: center; gap: .5rem; text-decoration: none; }
.logo-icon { width: 34px; height: 34px; background: var(--primary); color: #fff; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: .9rem; flex-shrink: 0; }
.logo-text { font-weight: 700; font-size: 1rem; color: var(--text); }
.logo-text small { display: block; font-size: .68rem; font-weight: 500; color: var(--text-muted); line-height: 1; }
.navbar-nav { display: flex; align-items: center; gap: .75rem; }
.nav-link { color: var(--text); font-size: .875rem; font-weight: 500; padding: .35rem .5rem; border-radius: var(--radius-sm); transition: background var(--transition); text-decoration: none; position: relative; }
.nav-link:hover { background: var(--bg); text-decoration: none; color: var(--primary); }
.nav-icon .badge { position: absolute; top: -4px; right: -4px; background: var(--danger); color: #fff; min-width: 16px; height: 16px; padding: 0 4px; font-size: .65rem; }
.nav-avatar { display: flex; align-items: center; gap: .5rem; background: none; border: 1.5px solid var(--border); padding: .3rem .6rem .3rem .3rem; border-radius: 100px; cursor: pointer; font-size: .875rem; font-weight: 500; color: var(--text); transition: border-color var(--transition), background var(--transition); }
.nav-avatar:hover { border-color: var(--primary); background: var(--primary-light); }
.dropdown { position: relative; }
.dropdown-menu { position: absolute; top: calc(100% + .5rem); right: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 8px 32px rgba(0,0,0,.12); min-width: 200px; padding: .4rem; display: none; z-index: 200; }
.dropdown-menu.open { display: block; }
.dropdown-item { display: block; padding: .5rem .75rem; font-size: .875rem; color: var(--text); border-radius: var(--radius-sm); transition: background var(--transition); text-decoration: none; }
.dropdown-item:hover { background: var(--bg); color: var(--primary); text-decoration: none; }
.dropdown-item.text-danger:hover { background: #fee2e2; color: var(--danger); }
.dropdown-divider { height: 1px; background: var(--border); margin: .35rem 0; }
.admin-link { color: var(--primary); font-weight: 600; }

/* Mobile nav */
.mobile-menu-btn { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.mobile-menu-btn span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: all .25s; }
.mobile-menu-btn.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mobile-menu-btn.active span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.mobile-menu { display: none; background: #fff; border-bottom: 1px solid var(--border); padding: 1rem; }
.mobile-menu.open { display: block; }
.mobile-menu-links a { display: block; padding: .625rem 0; color: var(--text); font-size: .9375rem; border-bottom: 1px solid var(--border); text-decoration: none; }
.mobile-menu-links hr { border: none; border-top: 1px solid var(--border); margin: .5rem 0; }

/* =============================================
   HERO
   ============================================= */
.page-home .hero { position: relative; overflow: hidden; background: linear-gradient(135deg, #1e3a8a 0%, #1d4ed8 50%, #2563eb 100%); color: #fff; padding: 5rem 0 4rem; }
.hero-bg-shapes { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.shape { position: absolute; border-radius: 50%; opacity: .12; }
.shape-1 { width: 400px; height: 400px; background: #93c5fd; top: -100px; right: -80px; }
.shape-2 { width: 250px; height: 250px; background: #bfdbfe; bottom: -80px; left: -60px; }
.shape-3 { width: 150px; height: 150px; background: #fbbf24; top: 40%; right: 20%; }
.hero .container { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; position: relative; z-index: 1; }
.hero-badge { display: inline-flex; align-items: center; gap: .5rem; background: rgba(255,255,255,.15); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,.2); padding: .35rem .875rem; border-radius: 100px; font-size: .8125rem; font-weight: 500; margin-bottom: 1.25rem; }
.pulse-dot { width: 8px; height: 8px; background: #4ade80; border-radius: 50%; animation: pulse 2s infinite; flex-shrink: 0; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.hero-title { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 900; line-height: 1.1; margin-bottom: 1.25rem; color: #fff; }
.hero-title .gradient-text { background: linear-gradient(90deg, #fbbf24, #f97316); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-subtitle { font-size: 1.0625rem; color: rgba(255,255,255,.85); max-width: 480px; margin-bottom: 2rem; line-height: 1.7; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.5rem; }
.hero-stats { display: flex; gap: 2rem; }
.hero-stat strong { display: block; font-size: 1.5rem; font-weight: 800; color: #fff; }
.hero-stat span { font-size: .8125rem; color: rgba(255,255,255,.7); }
.hero-visual { display: flex; justify-content: center; align-items: center; }
.hero-cards { position: relative; width: 340px; height: 340px; }
.hero-card { position: absolute; background: rgba(255,255,255,.95); backdrop-filter: blur(12px); border-radius: var(--radius); padding: .75rem 1rem; display: flex; align-items: center; gap: .75rem; box-shadow: 0 8px 24px rgba(0,0,0,.15); min-width: 200px; }
.hero-card strong { display: block; font-size: .875rem; color: var(--text); }
.hero-card small { color: var(--text-muted); font-size: .78rem; }
.hero-card-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; flex-shrink: 0; }
.floating-1 { top: 0;    left: 10px; animation: float1 4s ease-in-out infinite; }
.floating-2 { top: 90px; right: 0;   animation: float2 5s ease-in-out infinite; }
.floating-3 { bottom: 90px; left: 0; animation: float3 4.5s ease-in-out infinite; }
.floating-4 { bottom: 0; right: 20px; animation: float4 5.5s ease-in-out infinite; }
@keyframes float1 { 0%,100%{transform:translateY(0)}50%{transform:translateY(-10px)} }
@keyframes float2 { 0%,100%{transform:translateY(0)}50%{transform:translateY(-8px)} }
@keyframes float3 { 0%,100%{transform:translateY(0)}50%{transform:translateY(-12px)} }
@keyframes float4 { 0%,100%{transform:translateY(0)}50%{transform:translateY(-6px)} }

/* =============================================
   SECTIONS
   ============================================= */
.section { padding: 5rem 0; }
.section-header { text-align: center; margin-bottom: 3rem; }
.section-header h2 { margin-bottom: .5rem; }
.section-header p { color: var(--text-muted); font-size: 1.0625rem; }
.section-header .btn { margin-top: 0; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.section-head h2 { margin: 0; }

/* CATEGORIES */
.categories-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
.category-card { background: #fff; border: 1.5px solid var(--border); border-radius: var(--radius); padding: 1.5rem; transition: all var(--transition); text-decoration: none; color: var(--text); display: flex; flex-direction: column; gap: .5rem; }
.category-card:hover { border-color: var(--primary); box-shadow: var(--card-shadow-hover); transform: translateY(-2px); text-decoration: none; }
.category-icon { font-size: 2rem; }
.category-card h3 { font-size: 1rem; font-weight: 700; color: var(--text); }
.category-card p  { font-size: .8125rem; color: var(--text-muted); line-height: 1.5; }
.category-arrow  { font-size: .8rem; color: var(--primary); font-weight: 500; margin-top: auto; }

/* STEPS */
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; }
.step { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 2rem 1.5rem; }
.step-number { font-size: 2.5rem; font-weight: 900; color: var(--primary-light); line-height: 1; margin-bottom: .75rem; }
.step h3 { margin-bottom: .5rem; }
.step p  { font-size: .875rem; color: var(--text-muted); }

/* TRUST */
.section-trust { background: #f0f7ff; }
.trust-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.trust-content h2 { margin-bottom: 1rem; }
.trust-content p  { color: var(--text-muted); margin-bottom: 1.5rem; }
.trust-list { margin-bottom: 2rem; }
.trust-list li { display: flex; align-items: center; gap: .75rem; padding: .5rem 0; font-size: .9375rem; }
.check { color: var(--success); font-weight: 700; font-size: 1rem; }
.trust-visual { display: flex; justify-content: center; }
.trust-badge-large { background: #fff; border: 2px solid var(--primary-light); border-radius: var(--radius-lg); padding: 3rem 2rem; text-align: center; box-shadow: var(--card-shadow); }
.trust-icon { font-size: 3rem; margin-bottom: 1rem; }
.trust-badge-large h3 { color: var(--text); margin-bottom: .5rem; }
.trust-badge-large p  { color: var(--text-muted); font-size: .875rem; }

/* CTA */
.section-cta { background: linear-gradient(135deg, #1e3a8a, #2563eb); color: #fff; padding: 5rem 0; text-align: center; }
.section-cta h2 { color: #fff; margin-bottom: 1rem; }
.section-cta p  { color: rgba(255,255,255,.8); font-size: 1.0625rem; margin-bottom: 2rem; }
.cta-actions  { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1rem; }
.cta-small    { font-size: .8125rem; color: rgba(255,255,255,.6); }

/* =============================================
   LISTING CARDS
   ============================================= */
.listings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.listings-grid-sm { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.listing-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: all var(--transition); }
.listing-card:hover { box-shadow: var(--card-shadow-hover); transform: translateY(-2px); border-color: #d1d5db; }
.listing-card-image { position: relative; aspect-ratio: 4/3; overflow: hidden; background: #f3f4f6; }
.listing-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.listing-card:hover .listing-card-image img { transform: scale(1.03); }
.listing-card-image .badge-category { position: absolute; bottom: .5rem; left: .5rem; }
.fav-btn { position: absolute; top: .5rem; right: .5rem; background: rgba(255,255,255,.9); border: none; width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-muted); transition: all var(--transition); z-index: 2; }
.fav-btn:hover, .fav-btn.active { color: #ef4444; background: #fff; }
.listing-card-body { padding: .875rem; }
.listing-title { font-size: .9rem; font-weight: 600; color: var(--text); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-decoration: none; }
.listing-title:hover { color: var(--primary); text-decoration: none; }
.listing-price { display: flex; align-items: center; gap: .5rem; margin: .5rem 0; }
.listing-price { font-size: 1.0625rem; font-weight: 700; color: var(--primary); }
.price-free { color: var(--success); }
.condition-tag { font-size: .7rem; font-weight: 600; padding: .15rem .45rem; border-radius: 100px; text-transform: capitalize; }
.condition-new      { background: #dcfce7; color: #166534; }
.condition-like_new { background: #dbeafe; color: #1e40af; }
.condition-good     { background: #fef9c3; color: #854d0e; }
.condition-fair     { background: #ffedd5; color: #9a3412; }
.condition-poor     { background: #fee2e2; color: #991b1b; }
.listing-location { font-size: .78rem; color: var(--text-muted); display: flex; align-items: center; gap: .25rem; margin-bottom: .5rem; }
.listing-card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: .5rem; border-top: 1px solid var(--border); }
.listing-seller { display: flex; align-items: center; gap: .4rem; font-size: .78rem; color: var(--text-muted); }
.listing-time   { font-size: .75rem; color: var(--text-muted); }

/* AVATARS */
.avatar-xs { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar-sm { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar-md { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar-lg { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }

/* STARS */
.stars { color: #d1d5db; font-size: .9rem; }
.stars .filled { color: #f59e0b; }

/* =============================================
   MARKETPLACE
   ============================================= */
.marketplace-layout { display: grid; grid-template-columns: 240px 1fr; gap: 2rem; max-width: 1200px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.filter-sidebar { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; align-self: start; position: sticky; top: calc(var(--nav-h) + 1rem); }
.filter-sidebar-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.filter-sidebar-header h3 { font-size: 1rem; }
.sidebar-close { display: none; background: none; border: none; font-size: 1.5rem; cursor: pointer; color: var(--text-muted); }
.filter-group { margin-bottom: 1.25rem; border-bottom: 1px solid var(--border); padding-bottom: 1.25rem; }
.filter-group:last-child { border-bottom: none; }
.filter-label { font-size: .8125rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: .75rem; display: block; }
.category-filter-list li { margin-bottom: .2rem; }
.category-filter-list a { display: block; padding: .4rem .5rem; border-radius: var(--radius-sm); font-size: .875rem; color: var(--text); transition: all var(--transition); text-decoration: none; }
.category-filter-list a:hover, .category-filter-list a.active { background: var(--primary-light); color: var(--primary); font-weight: 600; text-decoration: none; }
.price-range-inputs { display: flex; align-items: center; gap: .5rem; }
.price-range-inputs span { color: var(--text-muted); }
.marketplace-search-bar { margin-bottom: 1.25rem; }
.search-form-inline { display: flex; align-items: center; gap: .75rem; }
.search-input-group { flex: 1; position: relative; display: flex; }
.search-icon { position: absolute; left: .875rem; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
.search-input-group .form-control { padding-left: 2.5rem; border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.search-input-group .btn { border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.filter-toggle { display: none; }
.marketplace-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.marketplace-title { font-size: 1.375rem; }
.listing-count { font-size: .9rem; font-weight: 400; color: var(--text-muted); margin-left: .5rem; }
.sort-controls { display: flex; align-items: center; gap: .5rem; font-size: .875rem; }
.empty-state { text-align: center; padding: 4rem 1rem; }
.empty-state.large { padding: 6rem 1rem; }
.empty-icon { font-size: 3rem; margin-bottom: 1rem; }
.empty-state h2, .empty-state h3 { margin-bottom: .5rem; }
.empty-state p { color: var(--text-muted); margin-bottom: 1.5rem; }
.pagination { display: flex; gap: .5rem; justify-content: center; margin-top: 2rem; }
.page-btn { padding: .45rem .875rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: .875rem; color: var(--text); text-decoration: none; transition: all var(--transition); }
.page-btn:hover { border-color: var(--primary); color: var(--primary); text-decoration: none; }
.page-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }

/* =============================================
   LISTING DETAIL
   ============================================= */
.listing-detail-layout { padding: 1.5rem 1rem 3rem; }
.breadcrumb { font-size: .8125rem; color: var(--text-muted); margin-bottom: 1.25rem; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary); }
.listing-detail-grid { display: grid; grid-template-columns: 1fr 320px; gap: 2rem; }
.gallery-main { border-radius: var(--radius); overflow: hidden; background: #f3f4f6; aspect-ratio: 4/3; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: flex; gap: .5rem; margin-top: .75rem; }
.gallery-thumb { width: 72px; height: 54px; object-fit: cover; border-radius: var(--radius-sm); cursor: pointer; border: 2px solid transparent; opacity: .7; transition: all var(--transition); }
.gallery-thumb.active, .gallery-thumb:hover { border-color: var(--primary); opacity: 1; }
.listing-info-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; margin-top: 1.25rem; }
.listing-detail-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1rem; }
.listing-detail-title { font-size: 1.375rem; font-weight: 800; margin-top: .35rem; }
.listing-detail-price { font-size: 1.375rem; font-weight: 800; color: var(--primary); white-space: nowrap; }
.listing-detail-meta { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; font-size: .8125rem; color: var(--text-muted); padding: .75rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.listing-detail-meta span { display: flex; align-items: center; gap: .3rem; }
.detail-section { background: #f9fafb; border-radius: var(--radius-sm); padding: 1rem; margin: 1rem 0; }
.detail-section h3 { font-size: .9rem; margin-bottom: .75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.detail-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: .75rem; margin-bottom: .75rem; }
.detail-item span { display: block; font-size: .75rem; color: var(--text-muted); margin-bottom: .15rem; }
.detail-item strong { font-size: .875rem; }
.detail-row { display: flex; align-items: center; gap: .75rem; padding: .5rem 0; font-size: .875rem; }
.detail-text { margin: .75rem 0; font-size: .875rem; }
.amenities-list { display: flex; flex-wrap: wrap; gap: .5rem; }
.amenity-tag { background: var(--primary-light); color: var(--primary); padding: .25rem .625rem; border-radius: 100px; font-size: .78rem; font-weight: 600; }
.listing-description { margin: 1.25rem 0; }
.listing-description h3 { margin-bottom: .75rem; font-size: 1rem; }
.description-text { font-size: .9375rem; line-height: 1.8; color: var(--text); }
.listing-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--border); }
.seller-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; }
.seller-card-header { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1rem; }
.seller-card-header h3 { font-size: 1rem; margin: 0 0 .2rem; }
.seller-card-header a { color: var(--text); text-decoration: none; }
.seller-card-header a:hover { color: var(--primary); }
.seller-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; text-align: center; margin-bottom: 1rem; padding: .75rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.seller-stat strong { display: block; font-size: 1.125rem; font-weight: 700; }
.seller-stat span   { font-size: .75rem; color: var(--text-muted); }
.safety-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; margin-top: 1rem; }
.safety-card h4 { margin-bottom: .75rem; }
.safety-card li { font-size: .8125rem; color: var(--text-muted); padding: .25rem 0; border-bottom: 1px solid var(--border); }
.safety-card li:last-child { border-bottom: none; }
.safety-card a { color: var(--primary); }
.section-reviews, .section-related { margin-top: 3rem; }
.section-reviews h2, .section-related h2 { margin-bottom: 1.5rem; }
.reviews-list { display: flex; flex-direction: column; gap: 1.25rem; }
.review-item { display: flex; gap: 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--border); }
.review-item:last-child { border-bottom: none; }
.review-body { flex: 1; }
.review-header { display: flex; align-items: center; gap: .75rem; margin-bottom: .4rem; flex-wrap: wrap; }
.review-header strong { font-size: .9rem; }
.review-body p { font-size: .875rem; color: var(--text); }

/* =============================================
   DASHBOARD
   ============================================= */
.page-dashboard { padding: 1.5rem 1rem 3rem; }
.dashboard-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.5rem; gap: 1rem; flex-wrap: wrap; }
.dashboard-welcome { display: flex; align-items: center; gap: 1rem; }
.dashboard-welcome h1 { font-size: 1.5rem; margin: 0; }
.dashboard-welcome p { margin: .25rem 0 0; }
.stats-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.25rem; display: flex; align-items: center; gap: 1rem; }
.stat-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; flex-shrink: 0; }
.stat-info strong { display: block; font-size: 1.375rem; font-weight: 800; }
.stat-info span { font-size: .8125rem; color: var(--text-muted); }
.dashboard-grid { display: grid; grid-template-columns: 1fr 340px; gap: 1.5rem; }
.dashboard-sidebar { display: flex; flex-direction: column; gap: 1.25rem; }
.dashboard-section { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; }
.my-listings-list { display: flex; flex-direction: column; gap: .75rem; }
.my-listing-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: .75rem 0; border-bottom: 1px solid var(--border); }
.my-listing-row:last-child { border-bottom: none; }
.my-listing-title { font-weight: 600; font-size: .9rem; color: var(--text); text-decoration: none; display: block; margin: .2rem 0; }
.my-listing-title:hover { color: var(--primary); }
.category-tag { font-size: .72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.my-listing-meta { display: flex; align-items: center; gap: .5rem; font-size: .78rem; flex-wrap: wrap; }
.price-tag { font-weight: 700; color: var(--primary); }
.my-listing-actions { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; }
.notif-list { display: flex; flex-direction: column; }
.notif-item { padding: .75rem 0; border-bottom: 1px solid var(--border); }
.notif-item:last-child { border-bottom: none; }
.notif-item.unread { background: var(--primary-light); margin: 0 -.75rem; padding: .75rem; border-radius: var(--radius-sm); border-bottom: none; margin-bottom: .35rem; }
.notif-content strong { font-size: .875rem; display: block; }
.notif-content p { font-size: .8125rem; color: var(--text-muted); margin: .15rem 0; }
.notif-content small { font-size: .72rem; color: var(--text-muted); }
.msg-preview-list { display: flex; flex-direction: column; }
.msg-preview-item { display: flex; align-items: center; gap: .75rem; padding: .75rem 0; border-bottom: 1px solid var(--border); }
.msg-preview-item:last-child { border-bottom: none; }
.msg-preview-body { flex: 1; overflow: hidden; }
.msg-preview-body strong { font-size: .875rem; display: block; }
.msg-preview-body p { font-size: .78rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mt-4 { margin-top: 1.5rem; }

/* =============================================
   AUTH
   ============================================= */
.page-auth { background: linear-gradient(135deg, #f0f7ff 0%, #e8f0fe 100%); min-height: 100vh; }
.auth-layout { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; }
.auth-panel { display: flex; flex-direction: column; padding: 2.5rem; }
.auth-panel-left { background: linear-gradient(135deg, #1e3a8a, #2563eb); color: #fff; gap: 2rem; }
.auth-panel-left .logo { color: #fff; }
.auth-panel-left .logo-text { color: #fff; }
.auth-panel-left .logo-text small { color: rgba(255,255,255,.6); }
.auth-promo h2 { font-size: 1.375rem; color: #fff; margin-bottom: 1.25rem; }
.auth-features { display: flex; flex-direction: column; gap: .625rem; }
.auth-features li { font-size: .9375rem; color: rgba(255,255,255,.85); }
.auth-quote { color: rgba(255,255,255,.55); font-style: italic; font-size: .875rem; margin-top: auto; padding-top: 2rem; }
.auth-panel-right { justify-content: center; background: #fff; }
.auth-form-wrapper { max-width: 440px; width: 100%; }
.auth-form-wrapper h1 { font-size: 1.75rem; margin-bottom: .35rem; }
.auth-subtitle { font-size: .875rem; color: var(--text-muted); margin-bottom: 1.5rem; }
.auth-form { display: flex; flex-direction: column; }
.auth-divider { display: flex; align-items: center; gap: 1rem; margin: 1.25rem 0; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-divider span { color: var(--text-muted); font-size: .8125rem; }
.auth-register-link { text-align: center; font-size: .875rem; color: var(--text-muted); }

/* =============================================
   MESSAGES
   ============================================= */
.messages-layout { padding: 1.5rem 1rem 3rem; }
.page-title { margin-bottom: 1.25rem; }
.messages-grid { display: grid; grid-template-columns: 320px 1fr; gap: 1rem; height: calc(100vh - 180px); }
.conversations-panel { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.conversations-search { padding: .75rem; border-bottom: 1px solid var(--border); }
.conversations-list { flex: 1; overflow-y: auto; }
.conversation-item a { display: flex; align-items: center; gap: .75rem; padding: .875rem 1rem; text-decoration: none; transition: background var(--transition); border-bottom: 1px solid var(--border); }
.conversation-item.active a, .conversation-item a:hover { background: var(--primary-light); }
.conversation-info { flex: 1; overflow: hidden; }
.conversation-name { font-size: .875rem; font-weight: 600; color: var(--text); }
.conversation-preview { font-size: .78rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conversation-meta { display: flex; flex-direction: column; align-items: flex-end; gap: .3rem; }
.conversation-meta span { font-size: .72rem; color: var(--text-muted); }
.unread-count { background: var(--primary); color: #fff; border-radius: 100px; padding: .1rem .4rem; font-size: .7rem; font-weight: 700; }
.conversation-item.unread .conversation-name { color: var(--primary); }
.chat-panel { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); display: flex; flex-direction: column; overflow: hidden; }
.chat-header { display: flex; align-items: center; gap: .75rem; padding: .875rem 1rem; border-bottom: 1px solid var(--border); }
.chat-listing-ref { padding: .5rem 1rem; background: #f9fafb; font-size: .8125rem; color: var(--text-muted); display: flex; align-items: center; gap: .4rem; border-bottom: 1px solid var(--border); }
.chat-messages { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: .625rem; }
.chat-message { display: flex; flex-direction: column; max-width: 70%; }
.chat-message.sent { align-self: flex-end; align-items: flex-end; }
.chat-message.received { align-self: flex-start; align-items: flex-start; }
.message-bubble { padding: .625rem .875rem; border-radius: 16px; font-size: .875rem; line-height: 1.5; }
.chat-message.sent .message-bubble { background: var(--primary); color: #fff; border-bottom-right-radius: 4px; }
.chat-message.received .message-bubble { background: #f3f4f6; color: var(--text); border-bottom-left-radius: 4px; }
.message-time { font-size: .7rem; color: var(--text-muted); margin-top: .2rem; }
.chat-start { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; padding: 2rem; text-align: center; }
.chat-start-avatar img { width: 72px; height: 72px; border-radius: 50%; margin-bottom: 1rem; }
.chat-start p { margin-bottom: .5rem; }
.chat-input-form { padding: .75rem 1rem; border-top: 1px solid var(--border); }
.chat-input-group { display: flex; gap: .75rem; align-items: flex-end; }
.chat-input-group .form-control { flex: 1; resize: none; max-height: 100px; }
.chat-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; color: var(--text-muted); text-align: center; padding: 2rem; }

/* =============================================
   PROFILE
   ============================================= */
.profile-layout { padding: 1.5rem 1rem 3rem; }
.profile-grid { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; }
.profile-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; text-align: center; position: sticky; top: calc(var(--nav-h) + 1rem); }
.profile-avatar-wrap { position: relative; width: 100px; margin: 0 auto 1rem; }
.profile-avatar { width: 100px; height: 100px; border-radius: 50%; object-fit: cover; border: 3px solid var(--primary-light); }
.profile-verified-badge { position: absolute; bottom: 4px; right: 4px; background: var(--success); color: #fff; width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 700; border: 2px solid #fff; }
.profile-name { font-size: 1.25rem; font-weight: 800; margin-bottom: .25rem; }
.profile-university { color: var(--text-muted); font-size: .875rem; margin-bottom: .75rem; }
.profile-rating { display: flex; align-items: center; justify-content: center; gap: .5rem; font-size: .875rem; margin-bottom: 1rem; }
.profile-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem; margin-bottom: 1rem; }
.profile-bio { font-size: .875rem; color: var(--text-muted); margin-bottom: 1rem; line-height: 1.6; }
.profile-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; text-align: center; padding: 1rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.profile-meta-item strong { display: block; font-size: 1.25rem; font-weight: 800; }
.profile-meta-item span   { font-size: .72rem; color: var(--text-muted); }
.profile-section { margin-bottom: 2rem; }
.overall-rating { display: flex; align-items: center; gap: .5rem; font-size: .9rem; }

/* =============================================
   CREATE LISTING
   ============================================= */
.page-header { text-align: center; padding: 2rem 1rem 1rem; }
.page-header h1 { margin-bottom: .35rem; }
.form-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; margin-bottom: 1.25rem; }
.form-section-title { font-size: 1rem; font-weight: 700; color: var(--text); padding-bottom: .75rem; border-bottom: 1px solid var(--border); margin-bottom: 1.25rem; }
.category-select-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .625rem; }
.category-radio-option { cursor: pointer; }
.category-radio-option input { position: absolute; opacity: 0; pointer-events: none; }
.category-option-label { display: flex; align-items: center; gap: .5rem; padding: .625rem .875rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: .875rem; font-weight: 500; transition: all var(--transition); cursor: pointer; }
.category-radio-option input:checked + .category-option-label { border-color: var(--primary); background: var(--primary-light); color: var(--primary); }
.image-upload-area { border: 2px dashed var(--border); border-radius: var(--radius); min-height: 140px; cursor: pointer; transition: border-color var(--transition); overflow: hidden; }
.image-upload-area:hover { border-color: var(--primary); }
.upload-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 140px; gap: .5rem; color: var(--text-muted); text-align: center; padding: 1.5rem; }
.upload-icon { font-size: 2rem; }
.upload-placeholder h4 { font-size: .9375rem; color: var(--text); }
.upload-placeholder p { font-size: .8125rem; }
.image-preview-grid { display: flex; flex-wrap: wrap; gap: .75rem; padding: 1rem; }
.img-preview-item { position: relative; }
.img-preview-item img { width: 100px; height: 80px; object-fit: cover; border-radius: var(--radius-sm); }
.cover-badge { position: absolute; top: .25rem; left: .25rem; background: var(--primary); color: #fff; font-size: .65rem; font-weight: 700; padding: .1rem .4rem; border-radius: 100px; }

/* =============================================
   ADMIN
   ============================================= */
.admin-layout { padding: 1.5rem 1rem 3rem; }
.admin-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.5rem; }
.admin-tabs { display: flex; gap: .25rem; margin-bottom: 1.5rem; border-bottom: 2px solid var(--border); }
.admin-tab { background: none; border: none; padding: .75rem 1.25rem; font-size: .9rem; font-weight: 500; cursor: pointer; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all var(--transition); display: flex; align-items: center; gap: .5rem; }
.admin-tab:hover { color: var(--primary); }
.admin-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.admin-tab-panel { display: none; }
.admin-tab-panel.active { display: block; }
.admin-section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.admin-table th { text-align: left; padding: .625rem 1rem; background: #f9fafb; font-size: .78rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; border-bottom: 2px solid var(--border); }
.admin-table td { padding: .75rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
.admin-table tr:hover td { background: #f9fafb; }
.admin-table a { color: var(--primary); }

/* =============================================
   FOOTER
   ============================================= */
.footer { background: #111827; color: #9ca3af; padding: 4rem 0 2rem; margin-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 3rem; margin-bottom: 3rem; }
.footer-brand .logo-text { color: #fff; }
.footer-brand .logo-icon { background: var(--primary); }
.footer-brand p { font-size: .8875rem; margin-top: 1rem; color: #6b7280; line-height: 1.7; }
.footer-socials { display: flex; gap: .75rem; margin-top: 1.25rem; }
.footer-socials a { color: #6b7280; transition: color var(--transition); }
.footer-socials a:hover { color: #fff; }
.footer-links h4 { color: #fff; font-size: .9rem; margin-bottom: 1rem; }
.footer-links li { margin-bottom: .5rem; }
.footer-links a { color: #6b7280; font-size: .875rem; text-decoration: none; transition: color var(--transition); }
.footer-links a:hover { color: #fff; }
.footer-bottom { padding-top: 2rem; border-top: 1px solid #1f2937; display: flex; flex-direction: column; gap: .4rem; }
.footer-bottom p { font-size: .8125rem; color: #4b5563; }
.footer-universities { font-size: .75rem; color: #374151; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .listing-detail-grid { grid-template-columns: 1fr; }
  .trust-grid { grid-template-columns: 1fr; }
  .hero .container { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
}

@media (max-width: 768px) {
  .navbar-nav .btn:not(.mobile-menu-btn), .navbar-nav .nav-link:not(.mobile-menu-btn), .navbar-nav .dropdown, .navbar-nav .nav-icon { display: none; }
  .mobile-menu-btn { display: flex; }
  .form-row { grid-template-columns: 1fr; }
  .marketplace-layout { grid-template-columns: 1fr; }
  .filter-sidebar { display: none; position: fixed; top: 0; left: 0; height: 100vh; z-index: 300; border-radius: 0; overflow-y: auto; width: 280px; }
  .filter-sidebar.open { display: flex; flex-direction: column; }
  .sidebar-close { display: block; }
  .filter-toggle { display: flex; }
  .search-form-inline { flex-wrap: wrap; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .messages-grid { grid-template-columns: 1fr; grid-template-rows: auto 1fr; height: auto; }
  .conversations-panel { max-height: 250px; }
  .auth-layout { grid-template-columns: 1fr; }
  .auth-panel-left { display: none; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-card { position: static; }
  .hero-stats { gap: 1rem; }
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .admin-tabs { overflow-x: auto; }
  .dashboard-header { flex-direction: column; align-items: flex-start; }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .listing-detail-header { flex-direction: column; }
}
