:root {
  --ink: #102820;
  --teal: #1f6f5b;
  --teal-dark: #0d3d34;
  --mist: #e7f1ec;
  --accent: #e0852e;
  --accent-hover: #c46f1f;
  --card: #ffffff;
  --muted: #5a7268;
  --line: rgba(16, 40, 32, 0.1);
  --font-display: "Bricolage Grotesque", "Segoe UI", sans-serif;
  --font-body: "Manrope", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse at 0% 0%, rgba(31, 111, 91, 0.14), transparent 45%),
    radial-gradient(ellipse at 100% 10%, rgba(224, 133, 46, 0.1), transparent 40%),
    linear-gradient(180deg, #f3f7f5 0%, #e9f0ec 100%);
  color: var(--ink);
  font-family: var(--font-body);
}

body.is-landing {
  background: #0d3d34;
}

h1, h2, h3, .navbar-brand, .landing-brand, .admin-sidebar .brand {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
}

.site-nav {
  background: rgba(13, 61, 52, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  z-index: 20;
  padding-top: 0.55rem;
  padding-bottom: 0.55rem;
}

.site-nav .navbar-brand {
  font-size: 1.3rem;
  letter-spacing: 0.06em;
}

.nav-pills-app .nav-link {
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  color: rgba(255,255,255,0.78) !important;
  font-weight: 500;
  font-size: 0.92rem;
}
.nav-pills-app .nav-link:hover {
  background: rgba(255,255,255,0.08);
  color: #fff !important;
}
.nav-pills-app .nav-link.active {
  background: rgba(255,255,255,0.14) !important;
  color: #fff !important;
}

.nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.3rem;
  margin-left: 0.25rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
}
.nav-badge.danger { background: #d64545; }

.nav-user {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: #fff;
}
.nav-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2a8f76, #e0852e);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.nav-user__meta {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.nav-user__meta strong { font-size: 0.85rem; }
.nav-user__meta small { font-size: 0.72rem; opacity: 0.7; text-transform: capitalize; }

.btn-nav-out {
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  background: transparent;
}
.btn-nav-out:hover { background: rgba(255,255,255,0.1); color: #fff; }

.app-main { flex: 1; }
.app-container { max-width: 1100px; }

.page-hero {
  margin-bottom: 1.35rem;
  padding: 1.35rem 1.5rem;
  border-radius: 1.25rem;
  background:
    linear-gradient(120deg, rgba(13, 61, 52, 0.96), rgba(31, 111, 91, 0.88)),
    url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none'%3E%3Cg fill='%23ffffff' fill-opacity='0.06'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  color: #fff;
  box-shadow: 0 16px 40px rgba(13, 61, 52, 0.18);
}
.page-hero--admin {
  background: linear-gradient(120deg, #0d3d34, #1f6f5b);
  box-shadow: none;
  padding: 1rem 0 0;
  margin-bottom: 0.5rem;
}
.page-hero__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  opacity: 0.75;
  margin-bottom: 0.35rem;
}
.page-hero__title {
  font-size: clamp(1.55rem, 3vw, 2rem);
  margin: 0;
  font-weight: 700;
}
.page-hero__sub {
  margin: 0.45rem 0 0;
  opacity: 0.88;
  max-width: 40rem;
}

.panel-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin-bottom: 1rem;
}

.person-row {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.9rem 0.35rem;
  border-bottom: 1px solid var(--line);
}
.person-row:last-child { border-bottom: 0; }
.person-row .avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1f6f5b, #3aa38a);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}
.person-row .meta { flex: 1; min-width: 0; }
.person-row .meta strong { display: block; }
.person-row .meta span { color: var(--muted); font-size: 0.85rem; }
.person-row .when { color: var(--muted); font-size: 0.8rem; white-space: nowrap; }

.empty-state {
  text-align: center;
  padding: 2.5rem 1.25rem;
  color: var(--muted);
}
.empty-state__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  border-radius: 1.1rem;
  background: var(--mist);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}
.empty-state h3 {
  color: var(--ink);
  font-size: 1.1rem;
  margin-bottom: 0.35rem;
}

.status-pill {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--mist);
  color: var(--teal-dark);
}
.status-pill.pending { background: #fff3cd; color: #856404; }
.status-pill.approved, .status-pill.accepted, .status-pill.completed { background: #d9ebe4; color: #0d3d34; }
.status-pill.rejected, .status-pill.cancelled { background: #f8d7da; color: #842029; }
.status-pill.offered { background: #e7f1ff; color: #084298; }

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.inbox-item {
  border-radius: 0.75rem;
  padding: 0.75rem 0.85rem !important;
  margin-bottom: 0.35rem;
  border: 1px solid transparent !important;
}
.inbox-item:hover { background: var(--mist) !important; }
.inbox-item.fw-semibold {
  background: rgba(31, 111, 91, 0.08) !important;
  border-color: rgba(31, 111, 91, 0.15) !important;
}

.footer-brand {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.admin-body { background: #0b221e; }
.admin-shell { min-height: 100vh; }
.admin-sidebar {
  width: 260px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #0c1f1c, #081814);
  color: #fff;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.admin-sidebar__tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  opacity: 0.55;
}
.admin-sidebar__foot { margin-top: auto; }
.admin-sidebar .brand { color: #fff; font-weight: 700; text-decoration: none; font-size: 1.2rem; }
.admin-sidebar .nav-link {
  color: rgba(255,255,255,0.72);
  border-radius: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 0.85rem;
}
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active {
  background: rgba(31, 111, 91, 0.4);
  color: #fff;
}
.admin-main {
  background:
    radial-gradient(circle at 100% 0%, rgba(31, 111, 91, 0.1), transparent 35%),
    #f3f7f5;
  min-height: 100vh;
}

.pagination .page-link {
  border-radius: 0.5rem !important;
  margin: 0 0.15rem;
  color: var(--teal-dark);
  border-color: var(--line);
}
.pagination .page-item.active .page-link {
  background: var(--teal);
  border-color: var(--teal);
}

.btn-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
  border-radius: 999px;
  padding-inline: 1.25rem;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.btn-accent:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(224, 133, 46, 0.28);
}

.btn-ghost {
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.55);
  color: #fff;
  font-weight: 600;
  border-radius: 999px;
  padding-inline: 1.25rem;
  transition: background 0.2s ease, transform 0.2s ease;
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
  transform: translateY(-1px);
}

/* —— Landing —— */
.landing-main {
  padding: 0 !important;
  flex: 1;
}
.landing-main > .container-fluid {
  padding: 0;
}

.landing-hero {
  position: relative;
  min-height: calc(100vh - 56px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: #fff;
}

.landing-hero__media {
  position: absolute;
  inset: 0;
  background:
    url("https://images.unsplash.com/photo-1521737711867-e3b97375f902?auto=format&fit=crop&w=1920&q=80") center/cover no-repeat;
  transform: scale(1.05);
  animation: heroZoom 18s ease-in-out infinite alternate;
}

.landing-hero__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(8, 32, 28, 0.92) 0%, rgba(13, 61, 52, 0.72) 45%, rgba(13, 61, 52, 0.35) 100%),
    linear-gradient(to top, rgba(8, 32, 28, 0.85), transparent 45%);
}

.landing-hero__content {
  position: relative;
  z-index: 2;
  width: min(720px, 92%);
  margin: 0 auto 0 8%;
  padding: 4rem 0 5.5rem;
}

.landing-kicker {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  opacity: 0.8;
  margin-bottom: 0.75rem;
}

.landing-brand {
  font-size: clamp(3.2rem, 9vw, 6rem);
  font-weight: 700;
  line-height: 0.95;
  margin: 0 0 1rem;
}

.landing-lead {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  max-width: 34rem;
  line-height: 1.55;
  opacity: 0.92;
  margin-bottom: 1.75rem;
}

.landing-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.landing-scroll {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}
.landing-scroll span {
  display: block;
  width: 18px;
  height: 28px;
  border: 2px solid rgba(255,255,255,0.55);
  border-radius: 12px;
  position: relative;
}
.landing-scroll span::after {
  content: "";
  position: absolute;
  top: 6px;
  left: 50%;
  width: 4px;
  height: 4px;
  margin-left: -2px;
  border-radius: 50%;
  background: #fff;
  animation: scrollDot 1.6s ease-in-out infinite;
}

.landing-strip {
  background: linear-gradient(180deg, #f3f7f5, #e8f0ec);
  padding: 4rem 0 5rem;
  color: var(--ink);
}

.landing-strip__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.feature-tile {
  padding: 0.25rem 0.5rem;
}

.feature-icon {
  width: 52px;
  height: 52px;
  color: var(--teal);
  margin-bottom: 1rem;
}
.feature-icon svg { width: 100%; height: 100%; }

.feature-tile h2 {
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
}
.feature-tile p {
  color: var(--muted);
  margin: 0;
  line-height: 1.55;
}

@keyframes heroZoom {
  from { transform: scale(1.05); }
  to { transform: scale(1.12); }
}
@keyframes scrollDot {
  0%, 100% { opacity: 0.3; transform: translateY(0); }
  50% { opacity: 1; transform: translateY(8px); }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  animation: fadeUp 0.7s ease forwards;
}
.delay-1 { animation-delay: 0.12s; }
.delay-2 { animation-delay: 0.24s; }
.delay-3 { animation-delay: 0.36s; }
.delay-4 { animation-delay: 0.55s; }

/* —— App chrome —— */
.kpi-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 1rem;
  padding: 1.15rem 1.25rem;
  box-shadow: 0 12px 30px rgba(16, 40, 32, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(16, 40, 32, 0.08);
}
.kpi-card .label { color: var(--muted); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; }
.kpi-card .value { font-family: var(--font-display); font-size: 1.7rem; font-weight: 700; color: var(--teal-dark); }

.panel {
  background: var(--card);
  border-radius: 1.1rem;
  border: 1px solid var(--line);
  padding: 1.35rem;
  box-shadow: 0 12px 30px rgba(16, 40, 32, 0.04);
}

.auth-shell {
  min-height: calc(100vh - 180px);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 0;
  border-radius: 1.25rem;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 20px 50px rgba(16, 40, 32, 0.08);
  background: #fff;
}
.auth-visual {
  background:
    linear-gradient(160deg, rgba(13, 61, 52, 0.88), rgba(31, 111, 91, 0.55)),
    url("https://images.unsplash.com/photo-1600880292203-757bb62b4baf?auto=format&fit=crop&w=1200&q=80") center/cover;
  color: #fff;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 420px;
}
.auth-visual h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin-bottom: 0.75rem;
}
.auth-visual p { opacity: 0.9; max-width: 22rem; }
.auth-form {
  padding: 2.25rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.category-chip {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--mist);
  color: var(--teal-dark);
  text-decoration: none;
  font-size: 0.85rem;
  margin: 0.2rem;
  transition: background 0.2s ease, color 0.2s ease;
}
.category-chip:hover { background: #cfe3db; color: var(--ink); }
.category-chip.active { background: var(--teal); color: #fff; }

.seller-row {
  border-bottom: 1px solid var(--line);
  padding: 1.1rem 0;
  transition: background 0.15s ease;
}
.seller-row:hover { background: rgba(31, 111, 91, 0.04); }
.seller-row:last-child { border-bottom: 0; }

.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.72);
}
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { opacity: 0.85; }

body.is-landing .site-footer {
  background: #081f1a;
}

.message-thread {
  max-height: 420px;
  overflow-y: auto;
  background: linear-gradient(180deg, #f4f8f6, #eef4f1);
  border-radius: 0.9rem;
  padding: 1rem;
}
.msg-bubble {
  max-width: 80%;
  padding: 0.65rem 0.9rem;
  border-radius: 0.9rem;
  margin-bottom: 0.65rem;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px rgba(16, 40, 32, 0.04);
}
.msg-bubble.mine {
  margin-left: auto;
  background: #d9ebe4;
  border-color: transparent;
}

.form-control, .form-select {
  border-radius: 0.7rem;
  border-color: rgba(16, 40, 32, 0.15);
}
.form-control:focus, .form-select:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 0.2rem rgba(31, 111, 91, 0.15);
}

.table { --bs-table-bg: transparent; }
.table > :not(caption) > * > * { vertical-align: middle; }

@media (max-width: 991px) {
  .landing-hero__content { margin-left: 4%; padding-bottom: 4rem; }
  .landing-strip__grid { grid-template-columns: 1fr; gap: 2rem; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-visual { min-height: 220px; }
  .admin-sidebar { width: 100%; min-height: auto; }
  .admin-body .admin-shell { flex-direction: column; }
  .nav-user__meta { display: none; }
}
