/* ==========================================================
   LANCER.IQ — COMPONENTS CSS
   navbar · footer · sidebar · admin-sidebar
   Design: Clean professional (Upwork/Fiverr style) + RTL
   ========================================================== */

/* ── Variables ── */
:root {
  /* Brand */
  --green:       #1DBF73;
  --green-dark:  #19a463;
  --green-light: #e8faf2;
  --green-mid:   #c8f0dc;

  /* Neutrals */
  --white:  #ffffff;
  --gray-1: #f7f7f7;
  --gray-2: #efeff0;
  --gray-3: #dadbdd;
  --gray-4: #b5b6ba;
  --gray-5: #74767e;
  --gray-6: #404145;
  --gray-7: #222325;
  --black:  #0e0e0f;

  /* Semantic */
  --danger:   #e34234;
  --warning:  #f59e0b;
  --info:     #0ea5e9;
  --success:  #1DBF73;

  /* Layout */
  --header-h:   68px;
  --sidebar-w:  248px;
  --radius:     8px;
  --radius-lg:  12px;
  --radius-xl:  16px;
  --shadow-sm:  0 1px 4px rgba(0,0,0,.08);
  --shadow-md:  0 4px 16px rgba(0,0,0,.12);
  --shadow-lg:  0 8px 40px rgba(0,0,0,.16);
  --transition: .2s ease;

  /* Font */
  --font: 'IBM Plex Sans Arabic', 'Cairo', sans-serif;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--white);
  color: var(--gray-7);
  direction: rtl;
  line-height: 1.6;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: var(--font); color: inherit; }
.hidden { display: none !important; }


/* ==========================================================
   SITE HEADER / NAVBAR
   ========================================================== */
.site-header {
  position: fixed;
  top: 0; inset-inline: 0;
  height: var(--header-h);
  background: var(--white);
  border-bottom: 1px solid var(--gray-2);
  z-index: 900;
  display: flex;
  flex-direction: column;
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: var(--header-h);
  padding: 0 24px;
  max-width: 1440px;
  margin: 0 auto;
  width: 100%;
}

/* Logo */
.header-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  text-decoration: none;
}
.logo-svg { display: block; flex-shrink: 0; }
.logo-text {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--gray-7);
  letter-spacing: -.3px;
}
.logo-text em { font-style: normal; color: var(--green); }

/* Search */
.header-search {
  flex: 1;
  max-width: 560px;
  position: relative;
}
.hs-wrap {
  display: flex;
  align-items: center;
  border: 1.5px solid var(--gray-3);
  border-radius: 50px;
  overflow: hidden;
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.hs-wrap:focus-within {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(29,191,115,.12);
}
.hs-cat {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 16px;
  font-size: .82rem;
  font-weight: 600;
  color: var(--gray-6);
  white-space: nowrap;
  height: 42px;
  background: var(--gray-1);
  border-left: 1px solid var(--gray-3);
  flex-shrink: 0;
}
.hs-cat:hover { background: var(--gray-2); }
.hs-sep { display: none; }
.hs-input {
  flex: 1;
  height: 42px;
  padding: 0 14px;
  border: none;
  outline: none;
  font-size: .9rem;
  font-family: var(--font);
  color: var(--gray-7);
  background: transparent;
  direction: rtl;
  min-width: 0;
}
.hs-input::placeholder { color: var(--gray-4); }
.hs-btn {
  width: 46px;
  height: 42px;
  display: grid;
  place-items: center;
  background: var(--green);
  color: #fff;
  font-size: .95rem;
  flex-shrink: 0;
  transition: background var(--transition);
}
.hs-btn:hover { background: var(--green-dark); }

/* Category dropdown */
.hs-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 100%;
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  z-index: 99;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  animation: fadeDown .15s ease;
}
.hsd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius);
  font-size: .87rem;
  color: var(--gray-6);
  transition: background var(--transition), color var(--transition);
}
.hsd-item:hover { background: var(--gray-1); color: var(--gray-7); }
.hsd-icon {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: .78rem;
  flex-shrink: 0;
}

/* Center nav */
.header-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}
.hn-link {
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: .88rem;
  font-weight: 500;
  color: var(--gray-6);
  transition: background var(--transition), color var(--transition);
}
.hn-link:hover { background: var(--gray-1); color: var(--gray-7); }
.hn-link.active { color: var(--green); font-weight: 600; }

/* Guest buttons */
.header-guest { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.btn-hdr-ghost {
  padding: 8px 20px;
  border: 1.5px solid var(--gray-3);
  border-radius: var(--radius);
  font-size: .88rem;
  font-weight: 600;
  color: var(--gray-6);
  transition: var(--transition);
}
.btn-hdr-ghost:hover { border-color: var(--gray-6); color: var(--gray-7); }
.btn-hdr-green {
  padding: 8px 20px;
  background: var(--green);
  border-radius: var(--radius);
  font-size: .88rem;
  font-weight: 700;
  color: #fff;
  transition: background var(--transition), transform var(--transition);
}
.btn-hdr-green:hover { background: var(--green-dark); transform: translateY(-1px); }

/* Auth actions */
.header-auth { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

.hdr-sell-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border: 1.5px solid var(--green);
  border-radius: var(--radius);
  font-size: .82rem;
  font-weight: 700;
  color: var(--green);
  transition: var(--transition);
  white-space: nowrap;
}
.hdr-sell-btn:hover { background: var(--green-light); }

.hdr-icon-btn {
  position: relative;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--gray-5);
  transition: background var(--transition), color var(--transition);
}
.hdr-icon-btn:hover { background: var(--gray-1); color: var(--gray-7); }

.hdr-badge {
  position: absolute;
  top: 2px;
  left: 2px;
  min-width: 17px;
  height: 17px;
  background: var(--danger);
  color: #fff;
  font-size: .62rem;
  font-weight: 700;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--white);
}

.hdr-wallet {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border: 1.5px solid var(--gray-2);
  border-radius: var(--radius);
  font-size: .82rem;
  font-weight: 700;
  color: var(--gray-7);
  background: var(--gray-1);
  transition: var(--transition);
  white-space: nowrap;
}
.hdr-wallet:hover { border-color: var(--gray-3); background: var(--gray-2); }
.hdr-wallet svg { color: var(--green); }

/* Avatar + Dropdown */
.hdr-profile { position: relative; }
.hdr-avatar-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px 4px 4px;
  border: 1.5px solid var(--gray-2);
  border-radius: 50px;
  background: var(--white);
  cursor: pointer;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.hdr-avatar-wrap:hover { border-color: var(--gray-4); }
.hdr-avatar-wrap.open  { border-color: var(--green); box-shadow: 0 0 0 3px rgba(29,191,115,.1); }
.hdr-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: .85rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
#hdrChevron {
  color: var(--gray-5);
  transition: transform var(--transition);
  font-size: .65rem;
}
.hdr-avatar-wrap.open #hdrChevron { transform: rotate(180deg); }

/* Dropdown Menu */
.hdr-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 268px;
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: fadeDown .15s ease;
  z-index: 200;
}
.hdd-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--gray-1);
  border-bottom: 1px solid var(--gray-2);
}
.hdd-av {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.hdd-name  { font-size: .9rem; font-weight: 700; color: var(--gray-7); }
.hdd-email { font-size: .75rem; color: var(--gray-5); }
.hdd-balance {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--green-light);
  font-size: .82rem;
  color: var(--gray-6);
  border-bottom: 1px solid var(--green-mid);
}
.hdd-balance strong { font-weight: 800; color: var(--green-dark); flex: 1; }
.hdd-topup {
  padding: 3px 10px;
  background: var(--green);
  color: #fff;
  border-radius: 50px;
  font-size: .74rem;
  font-weight: 700;
  transition: background var(--transition);
}
.hdd-topup:hover { background: var(--green-dark); }
.hdd-sep { height: 1px; background: var(--gray-2); }
.hdd-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 16px;
  font-size: .87rem;
  color: var(--gray-6);
  transition: background var(--transition);
  width: 100%;
  text-align: right;
}
.hdd-item i { width: 16px; text-align: center; color: var(--gray-4); font-size: .82rem; }
.hdd-item:hover { background: var(--gray-1); color: var(--gray-7); }
.hdd-item:hover i { color: var(--green); }
.hdd-admin { color: var(--info) !important; }
.hdd-logout { color: var(--danger) !important; }
.hdd-logout:hover { background: #fff5f4 !important; }

/* Notifications Panel */
.notif-panel {
  position: absolute;
  top: var(--header-h);
  left: 80px;
  width: 380px;
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: 899;
  overflow: hidden;
  animation: fadeDown .15s ease;
}
.np-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--gray-2);
  background: var(--gray-1);
}
.np-head span { font-size: .93rem; font-weight: 700; color: var(--gray-7); }
.np-markall {
  font-size: .78rem;
  color: var(--green);
  font-weight: 600;
  transition: var(--transition);
}
.np-markall:hover { text-decoration: underline; }
.np-list { max-height: 360px; overflow-y: auto; }
.np-list::-webkit-scrollbar { width: 4px; }
.np-list::-webkit-scrollbar-thumb { background: var(--gray-3); border-radius: 4px; }

/* Notification items (injected by JS) */
.np-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 13px 16px;
  border-bottom: 1px solid var(--gray-2);
  cursor: pointer;
  transition: background var(--transition);
}
.np-item:hover { background: var(--gray-1); }
.np-item.unread { background: #f0fdf8; }
.np-item-icon {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: .8rem;
  flex-shrink: 0;
}
.np-item-text { font-size: .82rem; line-height: 1.5; color: var(--gray-6); flex: 1; }
.np-item-text b { color: var(--gray-7); font-weight: 600; }
.np-item-time { font-size: .72rem; color: var(--gray-4); margin-top: 3px; }
.np-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--gray-4);
}
.np-empty i { font-size: 2.2rem; display: block; margin-bottom: 10px; }
.np-empty p { font-size: .85rem; }
.np-viewall {
  display: block;
  text-align: center;
  padding: 13px;
  font-size: .83rem;
  font-weight: 600;
  color: var(--green);
  border-top: 1px solid var(--gray-2);
  transition: background var(--transition);
}
.np-viewall:hover { background: var(--green-light); }

/* Hamburger */
.hdr-burger {
  display: none;
  width: 38px; height: 38px;
  border-radius: var(--radius);
  align-items: center;
  justify-content: center;
  color: var(--gray-6);
  font-size: 1.1rem;
  background: var(--gray-1);
  border: 1px solid var(--gray-2);
  flex-shrink: 0;
}

/* Mobile Menu */
.mob-menu {
  position: fixed;
  top: var(--header-h);
  right: 0; left: 0;
  background: var(--white);
  border-bottom: 1px solid var(--gray-2);
  box-shadow: var(--shadow-md);
  z-index: 899;
  padding: 16px;
  animation: fadeDown .15s ease;
}
.mob-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1.5px solid var(--gray-3);
  border-radius: 50px;
  margin-bottom: 14px;
  color: var(--gray-4);
}
.mob-search input {
  flex: 1; border: none; outline: none;
  font-family: var(--font); font-size: .9rem;
  color: var(--gray-7); direction: rtl;
}
.mob-auth-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
}
.mob-login {
  flex: 1; text-align: center;
  padding: 9px;
  border: 1.5px solid var(--gray-3);
  border-radius: var(--radius);
  font-weight: 600; font-size: .88rem;
  color: var(--gray-7);
  transition: var(--transition);
}
.mob-login:hover { border-color: var(--gray-6); }
.mob-register {
  flex: 1; text-align: center;
  padding: 9px;
  background: var(--green);
  border-radius: var(--radius);
  font-weight: 700; font-size: .88rem;
  color: #fff;
  transition: var(--transition);
}
.mob-register:hover { background: var(--green-dark); }
.mob-user-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--green-light);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
}
.mob-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.mob-uname { font-size: .88rem; font-weight: 700; color: var(--gray-7); }
.mob-ubal  { font-size: .78rem; color: var(--green-dark); font-weight: 600; }
.mob-nav { display: flex; flex-direction: column; gap: 2px; }
.mob-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border-radius: var(--radius);
  font-size: .88rem;
  color: var(--gray-6);
  transition: background var(--transition);
  width: 100%;
  text-align: right;
}
.mob-item i { width: 18px; text-align: center; color: var(--gray-4); }
.mob-item:hover { background: var(--gray-1); color: var(--gray-7); }
.mob-out { color: var(--danger) !important; }
.mob-out:hover { background: #fff5f4 !important; }

/* Keyframes */
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* ==========================================================
   USER SIDEBAR
   ========================================================== */
.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 799;
  backdrop-filter: blur(2px);
}
.sidebar-backdrop.show { display: block; }

.user-sidebar {
  position: fixed;
  top: var(--header-h);
  right: 0;
  width: var(--sidebar-w);
  height: calc(100vh - var(--header-h));
  background: var(--white);
  border-left: 1px solid var(--gray-2);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  z-index: 800;
  transition: transform var(--transition);
}
.user-sidebar::-webkit-scrollbar { width: 3px; }
.user-sidebar::-webkit-scrollbar-thumb { background: var(--gray-2); border-radius: 4px; }

/* Close (mobile only) */
.usb-close {
  display: none;
  position: absolute;
  top: 12px;
  left: 12px;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--gray-2);
  color: var(--gray-5);
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  transition: var(--transition);
}
.usb-close:hover { background: var(--gray-3); color: var(--gray-7); }

/* User card */
.usb-user {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 20px 16px 16px;
  border-bottom: 1px solid var(--gray-2);
}
.usb-avatar-wrap { position: relative; flex-shrink: 0; }
.usb-avatar {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  display: grid;
  place-items: center;
}
.usb-online {
  position: absolute;
  bottom: 0; left: 0;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--green);
  border: 2px solid var(--white);
}
.usb-name  { font-size: .88rem; font-weight: 700; color: var(--gray-7); }
.usb-level { font-size: .73rem; color: var(--gray-5); display: flex; align-items: center; gap: 4px; }
.usb-level i { color: #f5a623; font-size: .65rem; }
.usb-settings {
  margin-right: auto;
  width: 30px; height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--gray-4);
  font-size: .85rem;
  transition: var(--transition);
}
.usb-settings:hover { background: var(--gray-2); color: var(--gray-6); }

/* Balance */
.usb-balance {
  margin: 12px;
  padding: 14px;
  background: linear-gradient(135deg, var(--green) 0%, #16a05f 100%);
  border-radius: var(--radius-lg);
  color: #fff;
}
.usb-bal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.usb-bal-label { font-size: .73rem; opacity: .85; margin-bottom: 3px; }
.usb-bal-amount {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -.5px;
}
.usb-bal-icon {
  width: 38px; height: 38px;
  background: rgba(255,255,255,.2);
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
}
.usb-bal-actions { display: flex; gap: 6px; }
.usb-bal-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 8px;
  border-radius: 8px;
  font-size: .76rem;
  font-weight: 600;
  transition: var(--transition);
}
.usb-bal-btn.green {
  background: #fff;
  color: var(--green-dark);
}
.usb-bal-btn.green:hover { background: var(--green-light); }
.usb-bal-btn.gray {
  background: rgba(255,255,255,.2);
  color: #fff;
}
.usb-bal-btn.gray:hover { background: rgba(255,255,255,.3); }

/* Nav */
.usb-nav {
  flex: 1;
  padding: 8px 8px 20px;
}
.usb-section {
  font-size: .67rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--gray-4);
  padding: 12px 10px 4px;
}
.usb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius);
  font-size: .86rem;
  color: var(--gray-6);
  transition: background var(--transition), color var(--transition);
  width: 100%;
  text-align: right;
  position: relative;
}
.usb-item i { width: 18px; text-align: center; font-size: .88rem; color: var(--gray-4); flex-shrink: 0; }
.usb-item span:not(.usb-badge) { flex: 1; }
.usb-item:hover { background: var(--gray-1); color: var(--gray-7); }
.usb-item:hover i { color: var(--green); }
.usb-item.active {
  background: var(--green-light);
  color: var(--green-dark);
  font-weight: 600;
}
.usb-item.active i { color: var(--green); }
.usb-item-green { color: var(--green); font-weight: 600; }
.usb-item-green i { color: var(--green); }
.usb-item-green:hover { background: var(--green-light); }

.usb-badge {
  min-width: 19px; height: 19px;
  background: var(--green);
  color: #fff;
  font-size: .65rem;
  font-weight: 700;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  flex-shrink: 0;
}
.usb-badge:empty { display: none; }

.usb-logout { color: var(--danger) !important; }
.usb-logout i { color: var(--danger) !important; }
.usb-logout:hover { background: #fff5f4 !important; }

.usb-sep { height: 1px; background: var(--gray-2); margin: 8px 4px; }


/* ==========================================================
   ADMIN SIDEBAR
   ========================================================== */
.admin-sidebar {
  position: fixed;
  top: 0; right: 0;
  width: var(--sidebar-w);
  height: 100vh;
  background: var(--gray-7);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  z-index: 900;
  transition: transform var(--transition);
}
.admin-sidebar::-webkit-scrollbar { width: 3px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 4px; }

/* Brand */
.asb-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.asb-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}
.asb-logo-name {
  display: block;
  font-size: .95rem;
  font-weight: 800;
  color: #fff;
}
.asb-logo-name em { font-style: normal; color: var(--green); }
.asb-logo-sub {
  display: block;
  font-size: .67rem;
  color: rgba(255,255,255,.4);
  letter-spacing: .5px;
}
.asb-close {
  width: 28px; height: 28px;
  border-radius: 6px;
  display: none;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.4);
  font-size: .8rem;
  transition: var(--transition);
}
.asb-close:hover { background: rgba(255,255,255,.08); color: #fff; }

/* Admin profile */
.asb-profile {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 16px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.asb-av {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green), #0ea5e9);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.asb-pname { font-size: .88rem; font-weight: 700; color: #fff; }
.asb-role {
  font-size: .7rem;
  color: var(--green);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}
.asb-role i { font-size: .65rem; }

/* Quick stats */
.asb-stats {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  gap: 0;
}
.asb-stat {
  flex: 1;
  text-align: center;
}
.asb-stat-val {
  font-size: 1rem;
  font-weight: 800;
  color: var(--green);
}
.asb-stat-lbl {
  font-size: .67rem;
  color: rgba(255,255,255,.4);
  margin-top: 2px;
}
.asb-stat-div {
  width: 1px;
  height: 30px;
  background: rgba(255,255,255,.08);
}

/* Admin Nav */
.asb-nav {
  flex: 1;
  padding: 8px 8px 20px;
}
.asb-section {
  font-size: .64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,.3);
  padding: 12px 10px 4px;
}
.asb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius);
  font-size: .85rem;
  color: rgba(255,255,255,.65);
  transition: background var(--transition), color var(--transition);
  width: 100%;
  text-align: right;
}
.asb-item i { width: 18px; text-align: center; font-size: .85rem; color: rgba(255,255,255,.35); flex-shrink: 0; }
.asb-item span:not(.asb-badge) { flex: 1; }
.asb-item:hover { background: rgba(255,255,255,.07); color: #fff; }
.asb-item:hover i { color: var(--green); }
.asb-item.active {
  background: rgba(29,191,115,.15);
  color: var(--green);
}
.asb-item.active i { color: var(--green); }

.asb-badge {
  min-width: 19px; height: 19px;
  background: var(--green);
  color: #fff;
  font-size: .63rem;
  font-weight: 700;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  flex-shrink: 0;
}
.asb-badge:empty { display: none; }
.asb-badge.orange { background: var(--warning); }
.asb-badge.red    { background: var(--danger); }

.asb-logout { color: rgba(239,68,68,.8) !important; }
.asb-logout i { color: rgba(239,68,68,.6) !important; }
.asb-logout:hover { background: rgba(239,68,68,.08) !important; color: var(--danger) !important; }

.asb-sep { height: 1px; background: rgba(255,255,255,.07); margin: 8px 4px; }


/* ==========================================================
   SITE FOOTER
   ========================================================== */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--gray-2);
  margin-top: auto;
}

.sf-top {
  padding: 60px 0 48px;
}
.sf-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.sf-top .sf-container {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
}

/* Brand */
.sf-brand {}
.sf-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--gray-7);
}
.sf-logo em { font-style: normal; color: var(--green); }
.sf-tagline {
  font-size: .86rem;
  color: var(--gray-5);
  line-height: 1.75;
  margin-bottom: 20px;
}
.sf-socials {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.sf-soc {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1.5px solid var(--gray-3);
  display: grid;
  place-items: center;
  color: var(--gray-5);
  transition: var(--transition);
}
.sf-soc:hover { border-color: var(--green); color: var(--green); background: var(--green-light); }
.sf-app-badges { display: flex; gap: 8px; flex-wrap: wrap; }
.sf-app-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1.5px solid var(--gray-3);
  border-radius: 8px;
  font-size: .78rem;
  font-weight: 600;
  color: var(--gray-6);
  transition: var(--transition);
}
.sf-app-btn:hover { border-color: var(--gray-6); color: var(--gray-7); }
.sf-app-btn i { font-size: 1rem; }

/* Cols */
.sf-col h4 {
  font-size: .88rem;
  font-weight: 700;
  color: var(--gray-7);
  margin-bottom: 16px;
  position: relative;
  padding-bottom: 10px;
}
.sf-col h4::after {
  content: '';
  position: absolute;
  bottom: 0; right: 0;
  width: 24px; height: 2px;
  background: var(--green);
  border-radius: 2px;
}
.sf-col ul { display: flex; flex-direction: column; gap: 9px; }
.sf-col a {
  font-size: .84rem;
  color: var(--gray-5);
  transition: color var(--transition);
  display: inline-block;
}
.sf-col a:hover { color: var(--green); }

/* Bottom bar */
.sf-bottom {
  background: var(--gray-7);
  padding: 16px 0;
}
.sf-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}
.sf-bottom p { font-size: .8rem; color: rgba(255,255,255,.45); }
.sf-payments {
  display: flex;
  align-items: center;
  gap: 14px;
}
.sf-payments img {
  height: 22px;
  opacity: .65;
  filter: grayscale(1) brightness(2);
  transition: opacity var(--transition);
}
.sf-payments img:hover { opacity: 1; }
.sf-bottom-links {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .78rem;
  color: rgba(255,255,255,.3);
}
.sf-bottom-links a {
  color: rgba(255,255,255,.45);
  transition: color var(--transition);
}
.sf-bottom-links a:hover { color: var(--green); }


/* ==========================================================
   SHARED LAYOUT HELPERS
   ========================================================== */

/* Dashboard layout */
.layout-dashboard {
  display: flex;
  padding-top: var(--header-h);
  min-height: 100vh;
}
.layout-main {
  flex: 1;
  margin-right: var(--sidebar-w);
  padding: 32px;
  min-width: 0;
  background: var(--gray-1);
}

/* Admin layout */
.layout-admin {
  display: flex;
  min-height: 100vh;
  background: #f0f0f0;
}
.layout-admin-main {
  flex: 1;
  margin-right: var(--sidebar-w);
  padding: 28px;
  min-width: 0;
}

/* Cards */
.card {
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--gray-2);
}
.card-title { font-size: .93rem; font-weight: 700; color: var(--gray-7); }
.card-body  { padding: 20px 22px; }

/* Stat cards */
.stat-card {
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: box-shadow var(--transition);
}
.stat-card:hover { box-shadow: var(--shadow-md); }
.stat-icon {
  width: 50px; height: 50px;
  border-radius: var(--radius-lg);
  display: grid;
  place-items: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.stat-icon.green   { background: var(--green-light); color: var(--green-dark); }
.stat-icon.blue    { background: #dbeafe; color: #1d4ed8; }
.stat-icon.orange  { background: #fff7ed; color: #c2410c; }
.stat-icon.purple  { background: #ede9fe; color: #6d28d9; }
.stat-val { font-size: 1.5rem; font-weight: 800; color: var(--gray-7); }
.stat-lbl { font-size: .78rem; color: var(--gray-5); margin-top: 2px; }
.stat-trend { font-size: .73rem; margin-top: 4px; font-weight: 600; }
.stat-trend.up   { color: var(--green); }
.stat-trend.down { color: var(--danger); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 20px;
  border-radius: var(--radius);
  font-size: .87rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  border: none;
  transition: var(--transition);
}
.btn-sm { padding: 6px 14px; font-size: .8rem; }
.btn-lg { padding: 12px 28px; font-size: .95rem; }

.btn-green  { background: var(--green); color: #fff; }
.btn-green:hover { background: var(--green-dark); transform: translateY(-1px); }

.btn-outline { background: transparent; border: 1.5px solid var(--gray-3); color: var(--gray-6); }
.btn-outline:hover { border-color: var(--gray-6); color: var(--gray-7); }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #c93325; }

.btn-ghost { background: var(--gray-1); color: var(--gray-6); border: 1px solid var(--gray-2); }
.btn-ghost:hover { background: var(--gray-2); }

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 50px;
  font-size: .73rem;
  font-weight: 600;
}
.badge-green   { background: var(--green-light); color: var(--green-dark); border: 1px solid var(--green-mid); }
.badge-orange  { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }
.badge-red     { background: #fff5f4; color: var(--danger); border: 1px solid #fecaca; }
.badge-blue    { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }
.badge-gray    { background: var(--gray-1); color: var(--gray-5); border: 1px solid var(--gray-2); }

/* Forms */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: .86rem;
  font-weight: 600;
  color: var(--gray-7);
  margin-bottom: 7px;
}
.form-req { color: var(--danger); margin-right: 2px; }
.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--gray-3);
  border-radius: var(--radius);
  font-size: .9rem;
  font-family: var(--font);
  color: var(--gray-7);
  background: var(--white);
  outline: none;
  direction: rtl;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-control:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(29,191,115,.12);
}
.form-control::placeholder { color: var(--gray-4); }
textarea.form-control { resize: vertical; min-height: 110px; }
.form-hint  { font-size: .75rem; color: var(--gray-4); margin-top: 5px; }
.form-error { font-size: .75rem; color: var(--danger); margin-top: 5px; display: flex; align-items: center; gap: 4px; }

/* Table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .87rem; }
th {
  padding: 12px 16px;
  background: var(--gray-1);
  border-bottom: 1px solid var(--gray-2);
  font-weight: 700;
  color: var(--gray-6);
  text-align: right;
  white-space: nowrap;
}
td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--gray-2);
  color: var(--gray-6);
  vertical-align: middle;
}
tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--gray-1); }

/* Toast */
.toast-wrap {
  position: fixed;
  bottom: 24px; left: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  background: var(--white);
  border: 1px solid var(--gray-2);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  font-size: .87rem;
  min-width: 280px;
  max-width: 340px;
  animation: toastIn .3s ease;
}
.toast.toast-success { border-right: 4px solid var(--green); }
.toast.toast-error   { border-right: 4px solid var(--danger); }
.toast.toast-warning { border-right: 4px solid var(--warning); }
.toast.toast-info    { border-right: 4px solid var(--info); }
.toast-icon { font-size: 1.1rem; flex-shrink: 0; }
.toast-success .toast-icon { color: var(--green); }
.toast-error   .toast-icon { color: var(--danger); }
.toast-warning .toast-icon { color: var(--warning); }
.toast-info    .toast-icon { color: var(--info); }
.toast-msg  { flex: 1; color: var(--gray-7); }
.toast-close { color: var(--gray-4); font-size: .8rem; cursor: pointer; }
.toast-close:hover { color: var(--gray-6); }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(-20px); }
  to   { opacity: 1; transform: none; }
}

/* Spinner */
.spinner {
  width: 32px; height: 32px;
  border: 3px solid var(--gray-2);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  margin: 0 auto;
}
.spinner-sm { width: 18px; height: 18px; border-width: 2.5px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--gray-4);
}
.empty-state i    { font-size: 3rem; display: block; margin-bottom: 16px; }
.empty-state h3   { font-size: 1rem; font-weight: 700; color: var(--gray-6); margin-bottom: 7px; }
.empty-state p    { font-size: .85rem; }

/* Page header */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}
.page-title { font-size: 1.5rem; font-weight: 800; color: var(--gray-7); }
.page-sub   { font-size: .84rem; color: var(--gray-5); margin-top: 4px; }


/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 1024px) {
  .user-sidebar  { transform: translateX(100%); }
  .admin-sidebar { transform: translateX(100%); }
  .user-sidebar.open  { transform: none; }
  .admin-sidebar.open { transform: none; }
  .usb-close  { display: flex; }
  .asb-close  { display: flex; }
  .layout-main       { margin-right: 0; }
  .layout-admin-main { margin-right: 0; }
  .sf-top .sf-container { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 768px) {
  :root { --header-h: 60px; }
  .header-search { display: none; }
  .header-nav    { display: none; }
  .hdr-burger    { display: flex; }
  .btn-hdr-ghost { display: none; }
  .hdr-sell-btn  { display: none; }
  .hdr-wallet    { display: none; }

  .layout-main       { padding: 20px 16px; }
  .layout-admin-main { padding: 20px 16px; }

  .sf-top .sf-container { grid-template-columns: 1fr; gap: 28px; }
  .sf-bottom-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .header-inner { padding: 0 14px; gap: 10px; }
  .page-header  { flex-direction: column; }
} 

/* ================================================
   LANCER.IQ — MAIN STYLE (style.css)
   Home page + shared page styles
   ================================================ */

/* ── Page body offset ── */
body { padding-top: var(--header-h, 68px); }
body.no-header { padding-top: 0; }

/* ── Container ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ── Section ── */
.section { padding: 72px 0; }
.section.bg-gray { background: var(--gray-1); }

.section-head {
  text-align: center;
  margin-bottom: 44px;
  position: relative;
}
.section-head h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--gray-7);
  margin-bottom: 10px;
}
.section-head p {
  font-size: .95rem;
  color: var(--gray-5);
}
.sh-link {
  position: absolute;
  top: 0;
  left: 0;
  font-size: .87rem;
  font-weight: 600;
  color: var(--green);
}
.sh-link:hover { text-decoration: underline; }

/* ── Hero ── */
.hero-section {
  background: #fff;
  padding: 64px 0 80px;
  overflow: hidden;
  position: relative;
}
.hero-section::before {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(135deg, #f0fdf8 0%, #e8faf2 100%);
  z-index: 0;
}
.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: var(--green-light);
  border: 1px solid var(--green-mid);
  border-radius: 50px;
  font-size: .82rem;
  font-weight: 600;
  color: var(--green-dark);
  margin-bottom: 20px;
}
.hero-title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 900;
  line-height: 1.2;
  color: var(--gray-7);
  margin-bottom: 16px;
}
.hero-green { color: var(--green); }
.hero-sub {
  font-size: 1rem;
  color: var(--gray-5);
  line-height: 1.75;
  margin-bottom: 32px;
}

/* Hero Search */
.hero-search-wrap { margin-bottom: 28px; }
.hero-search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 2px solid var(--gray-3);
  border-radius: 12px;
  padding: 8px 8px 8px 16px;
  background: #fff;
  margin-bottom: 12px;
  transition: border-color .2s, box-shadow .2s;
}
.hero-search-box:focus-within {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(29,191,115,.1);
}
.hero-search-box i { color: var(--gray-4); font-size: 1rem; flex-shrink: 0; }
.hero-search-box input {
  flex: 1;
  border: none;
  outline: none;
  font-family: var(--font);
  font-size: .95rem;
  color: var(--gray-7);
  direction: rtl;
}
.hero-search-box input::placeholder { color: var(--gray-4); }
.hero-search-btn {
  padding: 10px 22px;
  background: var(--green);
  color: #fff;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 700;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  transition: background .2s;
  white-space: nowrap;
}
.hero-search-btn:hover { background: var(--green-dark); }
.hero-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: .82rem;
  color: var(--gray-4);
}
.hero-tags a {
  padding: 3px 12px;
  border: 1px solid var(--gray-3);
  border-radius: 50px;
  color: var(--gray-6);
  transition: .2s;
}
.hero-tags a:hover { border-color: var(--green); color: var(--green); background: var(--green-light); }

/* Hero Stats */
.hero-stats {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 18px 20px;
  background: var(--gray-1);
  border: 1px solid var(--gray-2);
  border-radius: 12px;
}
.hstat { flex: 1; text-align: center; }
.hstat strong { display: block; font-size: 1.2rem; font-weight: 800; color: var(--gray-7); }
.hstat span { font-size: .75rem; color: var(--gray-5); }
.hstat-sep { width: 1px; height: 32px; background: var(--gray-3); }

/* Hero Visual */
.hero-visual { position: relative; display: flex; align-items: center; justify-content: center; }
.hero-card-float {
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 8px 40px rgba(0,0,0,.12);
  width: 280px;
  animation: floatY 3s ease-in-out infinite;
}
@keyframes floatY {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
.hcf-top { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.hcf-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: .95rem;
  flex-shrink: 0;
}
.hcf-name { font-size: .85rem; font-weight: 700; color: var(--gray-7); }
.hcf-stars { font-size: .72rem; color: #f5a623; }
.hcf-stars span { color: var(--gray-6); font-weight: 600; }
.hcf-badge {
  margin-right: auto;
  padding: 3px 10px;
  background: var(--green-light);
  color: var(--green-dark);
  border-radius: 50px;
  font-size: .7rem;
  font-weight: 700;
}
.hcf-service {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px;
  background: var(--gray-1);
  border-radius: 10px;
  margin-bottom: 14px;
}
.hcf-simg {
  width: 48px; height: 48px;
  background: linear-gradient(135deg, #fef3c7, #fcd34d);
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  color: #d97706;
  flex-shrink: 0;
}
.hcf-stitle { font-size: .82rem; font-weight: 600; color: var(--gray-7); }
.hcf-sprice { font-size: .75rem; color: var(--gray-5); margin-top: 2px; }
.hcf-sprice strong { color: var(--green-dark); }
.hcf-btn {
  width: 100%;
  padding: 9px;
  background: var(--green);
  color: #fff;
  border-radius: 8px;
  font-size: .85rem;
  font-weight: 700;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  transition: .2s;
}
.hcf-btn:hover { background: var(--green-dark); }

.hero-badge-float {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,.1);
}
.hero-badge-float i { font-size: 1.3rem; }
.badge-secure { top: 20px; left: -30px; }
.badge-secure i { color: var(--green); }
.badge-fast i { color: #f59e0b; }
.hero-badge-float strong { display: block; font-size: .82rem; font-weight: 700; color: var(--gray-7); }
.hero-badge-float span { font-size: .72rem; color: var(--gray-5); }

/* ── Trusted Bar ── */
.trusted-bar {
  border-top: 1px solid var(--gray-2);
  border-bottom: 1px solid var(--gray-2);
  padding: 24px 0;
  background: var(--gray-1);
}
.trusted-bar .container {
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}
.tb-label { font-size: .8rem; color: var(--gray-4); white-space: nowrap; }
.tb-logos { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; flex: 1; }
.tb-logo {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: .88rem;
  font-weight: 600;
  color: var(--gray-4);
  transition: color .2s;
}
.tb-logo:hover { color: var(--gray-6); }
.tb-logo i { font-size: 1.1rem; }

/* ── Categories Grid ── */
.cats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.cat-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px 16px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  transition: box-shadow .2s, transform .2s, border-color .2s;
  cursor: pointer;
}
.cat-card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,.1);
  transform: translateY(-3px);
  border-color: var(--green);
}
.cat-ico {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  margin-bottom: 4px;
}
.cat-name { font-size: .9rem; font-weight: 700; color: var(--gray-7); }
.cat-count { font-size: .75rem; color: var(--gray-4); margin-top: auto; }
.cat-all .cat-ico { background: var(--gray-1); color: var(--gray-5); }

/* ── Services Grid ── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.svc-card {
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  overflow: hidden;
  transition: box-shadow .2s, transform .2s;
  cursor: pointer;
}
.svc-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,.1); transform: translateY(-3px); }
.svc-img {
  height: 150px;
  background: var(--gray-2);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  font-size: 2.5rem;
}
.svc-img.design  { background: linear-gradient(135deg,#fef3c7,#fcd34d); color: #d97706; }
.svc-img.dev     { background: linear-gradient(135deg,#dbeafe,#93c5fd); color: #1d4ed8; }
.svc-img.market  { background: linear-gradient(135deg,#fce7f3,#f9a8d4); color: #be185d; }
.svc-img.writing { background: linear-gradient(135deg,#d1fae5,#6ee7b7); color: #065f46; }
.svc-fav {
  position: absolute;
  top: 10px; left: 10px;
  width: 30px; height: 30px;
  background: rgba(255,255,255,.85);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: .85rem;
  color: var(--gray-5);
  cursor: pointer;
  border: none;
  transition: .2s;
}
.svc-fav:hover, .svc-fav.active { color: var(--danger); }
.svc-body { padding: 14px; }
.svc-seller {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 8px;
}
.svc-seller-av {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.svc-seller-name { font-size: .78rem; font-weight: 600; color: var(--gray-6); }
.svc-seller-lvl { margin-right: auto; font-size: .68rem; color: #f5a623; font-weight: 600; }
.svc-title {
  font-size: .87rem;
  font-weight: 600;
  color: var(--gray-7);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.svc-rating { display: flex; align-items: center; gap: 5px; font-size: .78rem; color: var(--gray-5); margin-bottom: 10px; }
.svc-rating i { color: #f5a623; }
.svc-rating strong { color: var(--gray-7); }
.svc-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--gray-2);
}
.svc-price-from { font-size: .72rem; color: var(--gray-4); }
.svc-price-val { font-size: 1rem; font-weight: 800; color: var(--gray-7); }
.svc-btn {
  padding: 5px 12px;
  background: var(--green-light);
  color: var(--green-dark);
  border-radius: 6px;
  font-size: .75rem;
  font-weight: 600;
  transition: .2s;
}
.svc-btn:hover { background: var(--green); color: #fff; }

/* Skeleton loaders */
.svc-skeleton {
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  height: 280px;
  animation: shimmer 1.5s infinite;
  background: linear-gradient(90deg, var(--gray-1) 25%, var(--gray-2) 50%, var(--gray-1) 75%);
  background-size: 200% 100%;
}
.fl-skeleton {
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  height: 200px;
  animation: shimmer 1.5s infinite;
  background: linear-gradient(90deg, var(--gray-1) 25%, var(--gray-2) 50%, var(--gray-1) 75%);
  background-size: 200% 100%;
}
@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── How It Works ── */
.how-grid {
  display: flex;
  align-items: center;
  gap: 16px;
}
.how-step {
  flex: 1;
  text-align: center;
  padding: 32px 20px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 16px;
  position: relative;
  transition: box-shadow .2s;
}
.how-step:hover { box-shadow: 0 4px 20px rgba(0,0,0,.09); }
.how-num {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px; height: 28px;
  background: var(--green);
  color: #fff;
  border-radius: 50%;
  font-size: .72rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}
.how-ico {
  width: 60px; height: 60px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  margin: 0 auto 16px;
}
.how-ico.green  { background: var(--green-light); color: var(--green-dark); }
.how-ico.blue   { background: #dbeafe; color: #1d4ed8; }
.how-ico.orange { background: #fff7ed; color: #c2410c; }
.how-step h3 { font-size: 1rem; font-weight: 700; color: var(--gray-7); margin-bottom: 10px; }
.how-step p { font-size: .84rem; color: var(--gray-5); line-height: 1.65; }
.how-arrow { color: var(--gray-3); font-size: 1.3rem; flex-shrink: 0; }

/* ── Freelancers Grid ── */
.freelancers-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.fl-card {
  text-align: center;
  padding: 24px 16px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  transition: box-shadow .2s, transform .2s;
}
.fl-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.1); transform: translateY(-3px); }
.fl-av {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 1.4rem;
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
}
.fl-name { font-size: .95rem; font-weight: 700; color: var(--gray-7); margin-bottom: 4px; }
.fl-spec { font-size: .78rem; color: var(--gray-5); margin-bottom: 8px; }
.fl-rating { font-size: .8rem; color: var(--gray-5); margin-bottom: 10px; }
.fl-rating i { color: #f5a623; }
.fl-tags { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center; margin-bottom: 14px; }
.fl-tag {
  padding: 3px 10px;
  background: var(--gray-1);
  border: 1px solid var(--gray-2);
  border-radius: 50px;
  font-size: .72rem;
  color: var(--gray-5);
}
.fl-view-btn {
  display: inline-block;
  padding: 8px 20px;
  border: 1.5px solid var(--green);
  border-radius: 8px;
  color: var(--green);
  font-size: .82rem;
  font-weight: 600;
  transition: .2s;
}
.fl-view-btn:hover { background: var(--green); color: #fff; }

/* ── Reviews ── */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.review-card {
  padding: 24px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: box-shadow .2s;
}
.review-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.09); }
.review-card.featured { border-color: var(--green); border-width: 2px; }
.rv-stars { color: #f5a623; font-size: 1rem; letter-spacing: 2px; }
.review-card p { font-size: .87rem; color: var(--gray-5); line-height: 1.7; flex: 1; }
.rv-author { display: flex; align-items: center; gap: 10px; padding-top: 12px; border-top: 1px solid var(--gray-2); }
.rv-av {
  width: 38px; height: 38px;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.rv-author b { display: block; font-size: .87rem; font-weight: 700; color: var(--gray-7); }
.rv-author span { font-size: .75rem; color: var(--gray-5); }

/* ── CTA ── */
.cta-section {
  background: var(--gray-7);
  padding: 72px 0;
  text-align: center;
}
.cta-inner h2 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 900;
  color: #fff;
  margin-bottom: 12px;
}
.cta-inner p { font-size: .95rem; color: rgba(255,255,255,.6); margin-bottom: 28px; }
.cta-btns { display: flex; align-items: center; justify-content: center; gap: 14px; margin-bottom: 16px; }
.btn-cta-green {
  padding: 13px 32px;
  background: var(--green);
  color: #fff;
  border-radius: 10px;
  font-weight: 700;
  font-size: .95rem;
  transition: .2s;
}
.btn-cta-green:hover { background: var(--green-dark); transform: translateY(-2px); }
.btn-cta-outline {
  padding: 12px 28px;
  border: 1.5px solid rgba(255,255,255,.3);
  color: rgba(255,255,255,.8);
  border-radius: 10px;
  font-weight: 600;
  font-size: .93rem;
  transition: .2s;
}
.btn-cta-outline:hover { border-color: #fff; color: #fff; }
.cta-note { font-size: .8rem; color: rgba(255,255,255,.35); display: flex; align-items: center; justify-content: center; gap: 6px; }

/* ── Auth Pages (login/register) ── */
.auth-page {
  min-height: 100vh;
  background: var(--gray-1);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
}
.auth-box {
  width: 100%;
  max-width: 460px;
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 16px;
  padding: 40px;
  box-shadow: 0 4px 24px rgba(0,0,0,.08);
}
.auth-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-bottom: 28px;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--gray-7);
  text-decoration: none;
}
.auth-logo em { font-style: normal; color: var(--green); }
.auth-logo svg { display: block; }
.auth-title { font-size: 1.3rem; font-weight: 800; color: var(--gray-7); margin-bottom: 6px; text-align: center; }
.auth-sub { font-size: .87rem; color: var(--gray-5); text-align: center; margin-bottom: 28px; }
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--gray-4);
  font-size: .8rem;
}
.auth-divider::before, .auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-2);
}
.auth-switch { text-align: center; margin-top: 20px; font-size: .87rem; color: var(--gray-5); }
.auth-switch a { color: var(--green); font-weight: 600; }
.auth-switch a:hover { text-decoration: underline; }
.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 11px;
  border: 1.5px solid var(--gray-3);
  border-radius: 10px;
  font-size: .88rem;
  font-weight: 600;
  color: var(--gray-7);
  background: #fff;
  cursor: pointer;
  font-family: var(--font);
  transition: .2s;
  margin-bottom: 10px;
}
.btn-social:hover { border-color: var(--gray-4); background: var(--gray-1); }
.btn-social img { width: 20px; height: 20px; }

/* ── Dashboard / Inner Pages ── */
.inner-page {
  min-height: calc(100vh - var(--header-h));
  background: var(--gray-1);
}
.inner-layout {
  display: flex;
  min-height: calc(100vh - var(--header-h));
}
.inner-sidebar { width: var(--sidebar-w); flex-shrink: 0; }
.inner-main {
  flex: 1;
  padding: 28px 32px;
  min-width: 0;
  max-width: 100%;
}

/* ── Service Details ── */
.service-detail-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 28px;
  align-items: start;
}
.svc-order-box {
  background: #fff;
  border: 1px solid var(--gray-2);
  border-radius: 12px;
  padding: 22px;
  position: sticky;
  top: calc(var(--header-h) + 20px);
}

/* ── Checkout ── */
.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 28px;
  align-items: start;
}

/* ── Messages ── */
.messages-layout {
  display: flex;
  height: calc(100vh - var(--header-h));
  overflow: hidden;
}
.msg-sidebar {
  width: 300px;
  border-left: 1px solid var(--gray-2);
  background: #fff;
  overflow-y: auto;
  flex-shrink: 0;
}
.msg-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--gray-1);
}
.msg-conv-area {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.msg-input-bar {
  padding: 14px 16px;
  background: #fff;
  border-top: 1px solid var(--gray-2);
  display: flex;
  gap: 10px;
  align-items: center;
}
.msg-input-bar input {
  flex: 1;
  padding: 10px 14px;
  border: 1.5px solid var(--gray-3);
  border-radius: 50px;
  outline: none;
  font-family: var(--font);
  font-size: .9rem;
  direction: rtl;
}
.msg-input-bar input:focus { border-color: var(--green); }

/* ── Admin Pages ── */
.admin-page {
  display: flex;
  min-height: 100vh;
  background: var(--gray-1);
}
.admin-page-main {
  flex: 1;
  margin-right: var(--sidebar-w);
  padding: 28px;
  min-width: 0;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .cats-grid { grid-template-columns: repeat(2, 1fr); }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .freelancers-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .service-detail-grid { grid-template-columns: 1fr; }
  .checkout-grid { grid-template-columns: 1fr; }
  .admin-page-main { margin-right: 0; }
}
@media (max-width: 768px) {
  .cats-grid { grid-template-columns: repeat(2, 1fr); }
  .services-grid { grid-template-columns: 1fr; }
  .freelancers-grid { grid-template-columns: repeat(2, 1fr); }
  .reviews-grid { grid-template-columns: 1fr; }
  .how-grid { flex-direction: column; }
  .how-arrow { transform: rotate(90deg); }
  .inner-main { padding: 20px 16px; }
}
@media (max-width: 480px) {
  .cats-grid { grid-template-columns: repeat(2, 1fr); }
  .freelancers-grid { grid-template-columns: 1fr; }
  .auth-box { padding: 28px 20px; }
  .cta-btns { flex-direction: column; }
}