/* ============================================================
   MSukasha.com - Main Stylesheet
   UPDATED: Header logo + search bar alignment fixed
   ============================================================ */

:root {
  --orange: #ff6600;
  --orange-dark: #e55a00;
  --orange-light: #fff4ee;
  --blue: #0066cc;
  --dark: #1a2332;
  --dark-2: #2d3a4a;
  --body-bg: #f2f4f7;
  --white: #ffffff;
  --border: #e2e6ea;
  --text: #2d3a4a;
  --muted: #6c7a8d;
  --radius: 10px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 6px 20px rgba(0,0,0,0.10);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.13);
  --transition: 0.25s ease;
  --font: 'Segoe UI', 'Inter', Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font); background: var(--body-bg); color: var(--text); line-height: 1.6; }
a { color: inherit; text-decoration: none; transition: color var(--transition); }
img { max-width: 100%; display: block; }
ul { list-style: none; }
button { cursor: pointer; font-family: var(--font); }
input, select, textarea { font-family: var(--font); }

.container { max-width: 1260px; margin: 0 auto; padding: 0 20px; }

/* ============================================================
   HEADER — FIXED
   ============================================================ */
.site-header {
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

/* Top bar */
.header-top {
  background: var(--dark);
  padding: 6px 0;
  font-size: 12px;
  color: rgba(255,255,255,0.7);
}
.header-top .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.header-top a { color: rgba(255,255,255,0.7); }
.header-top a:hover { color: #fff; }
.header-top-links { display: flex; gap: 18px; }

/* ── MAIN HEADER ROW ── */
.header-main {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.header-main .container {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 56px;          /* fixed height so all items are vertically centred */
}

/* Logo */
.site-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  height: 100%;
}
.site-logo img {
  height: 44px;
  width: auto;
  object-fit: contain;
  display: block;
}

/* ── SEARCH FORM — centred & full-height ── */
.search-form {
  flex: 1;
  display: flex;
  align-items: stretch;   /* children fill the full height */
  height: 44px;           /* matches logo height */
  max-width: 600px;
  border: 2px solid var(--orange);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.search-form select {
  border: none;
  outline: none;
  padding: 0 14px;
  font-size: 13px;
  color: var(--text);
  background: #f7f7f7;
  border-right: 1px solid var(--border);
  min-width: 148px;
  cursor: pointer;
  height: 100%;
  /* remove default arrow on some browsers for cleaner look */
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%236c7a8d'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}

.search-form input[type="text"] {
  flex: 1;
  border: none;
  outline: none;
  padding: 0 16px;
  font-size: 14px;
  height: 100%;
  background: #fff;
  color: var(--text);
}
.search-form input[type="text"]::placeholder { color: #aab0bb; }

.search-form button {
  background: var(--orange);
  color: #fff;
  border: none;
  padding: 0 22px;
  font-size: 14px;
  font-weight: 700;
  transition: background var(--transition);
  height: 100%;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}
.search-form button:hover { background: var(--orange-dark); }

/* ── HEADER ACTIONS ── */
.header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  flex-shrink: 0;
}

.hdr-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 7px 11px;
  border-radius: var(--radius);
  font-size: 11px;
  color: var(--text);
  border: 1px solid transparent;
  background: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.hdr-btn i { font-size: 18px; color: var(--dark); }
.hdr-btn:hover { background: var(--orange-light); color: var(--orange); border-color: var(--border); }
.hdr-btn:hover i { color: var(--orange); }
.hdr-btn.primary-btn {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
  flex-direction: row;
  gap: 6px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 700;
}
.hdr-btn.primary-btn i { color: #fff; font-size: 14px; }
.hdr-btn.primary-btn:hover { background: var(--orange-dark); }

/* ── NAV BAR ── */
.nav-bar { background: var(--dark); border-top: 1px solid rgba(255,255,255,0.07); }
.nav-bar .container {
  display: flex;
  align-items: center;
  height: 46px;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-bar .container::-webkit-scrollbar { display: none; }
.nav-bar a {
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  font-weight: 500;
  padding: 0 15px;
  height: 46px;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: all var(--transition);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  flex-shrink: 0;
}
.nav-bar a:hover, .nav-bar a.active {
  color: #fff;
  background: rgba(255,255,255,0.08);
  border-bottom-color: var(--orange);
}
.nav-bar a.all-cats {
  background: var(--orange);
  font-weight: 700;
  color: #fff;
  padding: 0 18px;
}
.nav-bar a.all-cats:hover { background: var(--orange-dark); }

/* ============================================================
   HERO
   ============================================================ */
.hero-section { padding: 24px 0; }
.hero-grid {
  display: grid;
  grid-template-columns: 230px 1fr 260px;
  gap: 18px;
  align-items: stretch;
}

.side-categories {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  border: 1px solid var(--border);
}
.side-cat-title {
  background: var(--dark);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.side-cat-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  font-size: 13px;
  color: var(--text);
  border-bottom: 1px solid #f5f5f5;
  transition: all var(--transition);
}
.side-cat-link i { width: 16px; color: var(--muted); font-size: 13px; }
.side-cat-link:hover { background: var(--orange-light); color: var(--orange); }
.side-cat-link:hover i { color: var(--orange); }
.side-cat-link.view-all { color: var(--orange); font-weight: 600; }

.hero-banner {
  background: linear-gradient(135deg, #1a2332 0%, #2d4a6e 60%, #1a3a5c 100%);
  border-radius: var(--radius);
  padding: 48px 48px;
  color: #fff;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 320px;
}
.hero-banner::before {
  content: '';
  position: absolute;
  right: -60px; top: -60px;
  width: 320px; height: 320px;
  background: rgba(255,102,0,0.15);
  border-radius: 50%;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,102,0,0.2);
  border: 1px solid rgba(255,102,0,0.4);
  color: #ffaa66;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 5px 12px;
  border-radius: 20px;
  margin-bottom: 18px;
  width: fit-content;
}
.hero-banner h1 { font-size: 36px; font-weight: 800; line-height: 1.2; margin-bottom: 14px; }
.hero-banner h1 span { color: var(--orange); }
.hero-banner p { font-size: 15px; opacity: 0.85; margin-bottom: 28px; max-width: 420px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.btn-primary {
  background: var(--orange);
  color: #fff;
  padding: 12px 26px;
  border-radius: 7px;
  font-weight: 700;
  font-size: 14px;
  border: 2px solid var(--orange);
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-primary:hover { background: var(--orange-dark); border-color: var(--orange-dark); }

.btn-outline-white {
  background: transparent;
  color: #fff;
  padding: 12px 24px;
  border-radius: 7px;
  font-weight: 600;
  font-size: 14px;
  border: 2px solid rgba(255,255,255,0.5);
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-outline-white:hover { border-color: #fff; background: rgba(255,255,255,0.1); }

.hero-right { display: flex; flex-direction: column; gap: 14px; }
.why-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  flex: 1;
}
.why-card h4 { font-size: 14px; font-weight: 700; margin-bottom: 12px; color: var(--dark); }
.why-list { display: flex; flex-direction: column; gap: 8px; }
.why-item { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.why-item i { color: var(--orange); font-size: 14px; width: 16px; }

.post-ad-card {
  background: var(--orange);
  border-radius: var(--radius);
  padding: 20px;
  color: #fff;
  text-align: center;
}
.post-ad-card h5 { font-size: 14px; font-weight: 700; margin-bottom: 6px; }
.post-ad-card p { font-size: 12px; opacity: 0.9; margin-bottom: 14px; }
.btn-white {
  background: #fff;
  color: var(--orange);
  padding: 9px 20px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 13px;
  border: none;
  transition: all var(--transition);
  display: inline-block;
  width: 100%;
}
.btn-white:hover { background: #ffe8d8; }

/* ============================================================
   SECTIONS & PRODUCT CARDS
   ============================================================ */
.section { margin: 30px 0; }
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.section-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--dark);
  position: relative;
  padding-left: 14px;
}
.section-title::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--orange);
  border-radius: 4px;
}
.see-all { font-size: 13px; color: var(--orange); font-weight: 600; display: flex; align-items: center; gap: 4px; }
.see-all:hover { color: var(--orange-dark); }

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
  gap: 18px;
}
.product-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: all var(--transition);
  position: relative;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: #d0d8e4; }

.card-img {
  height: 200px;
  background: linear-gradient(135deg, #f0f2f5, #e4e8ed);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-img .placeholder-icon { font-size: 48px; color: #c8d0d8; }

.card-badge {
  position: absolute;
  top: 10px; left: 10px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-b2b { background: var(--orange); color: #fff; }
.badge-used { background: #0099cc; color: #fff; }
.badge-new { background: #22c55e; color: #fff; }

.card-actions {
  position: absolute;
  top: 10px; right: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  opacity: 0;
  transform: translateX(8px);
  transition: all var(--transition);
}
.product-card:hover .card-actions { opacity: 1; transform: translateX(0); }
.card-action-btn {
  width: 32px; height: 32px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--text);
  transition: all var(--transition);
}
.card-action-btn:hover { background: var(--orange); color: #fff; border-color: var(--orange); }

.card-body { padding: 14px; }
.card-name { font-size: 13.5px; font-weight: 600; color: var(--text); line-height: 1.4; height: 38px; overflow: hidden; margin-bottom: 8px; }
.card-price { font-size: 17px; font-weight: 800; color: var(--orange); margin-bottom: 4px; }
.card-moq { font-size: 11px; color: var(--muted); }
.card-location { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 4px; margin-top: 6px; }
.card-footer { padding: 10px 14px; border-top: 1px solid #f0f0f0; display: flex; gap: 8px; }
.card-btn { flex: 1; padding: 8px; border-radius: 6px; font-size: 12px; font-weight: 600; text-align: center; border: 1px solid var(--orange); background: var(--orange-light); color: var(--orange); transition: all var(--transition); display: block; }
.card-btn:hover { background: var(--orange); color: #fff; }
.card-btn.solid { background: var(--orange); color: #fff; }
.card-btn.solid:hover { background: var(--orange-dark); }

/* ============================================================
   PROMO BANNER
   ============================================================ */
.promo-banner {
  background: linear-gradient(135deg, #1a2332, #2d3a4a);
  border-radius: var(--radius);
  padding: 30px 40px;
  margin: 30px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.promo-banner::after { content: ''; position: absolute; right: 200px; top: -50px; width: 200px; height: 200px; background: rgba(255,102,0,0.12); border-radius: 50%; }
.promo-text h2 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.promo-text p { font-size: 14px; opacity: 0.8; }

/* ============================================================
   CATEGORY CARDS
   ============================================================ */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 14px; }
.cat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px 14px;
  text-align: center;
  border: 1px solid var(--border);
  transition: all var(--transition);
  cursor: pointer;
}
.cat-card:hover { border-color: var(--orange); background: var(--orange-light); transform: translateY(-3px); }
.cat-card i { font-size: 28px; color: var(--orange); margin-bottom: 10px; }
.cat-card span { font-size: 12px; font-weight: 600; color: var(--text); display: block; }
.cat-card:hover span { color: var(--orange); }

/* ============================================================
   STATS BAR
   ============================================================ */
.stats-bar {
  background: var(--white);
  border-radius: var(--radius);
  padding: 24px 40px;
  margin: 30px 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  border: 1px solid var(--border);
}
.stat-item { text-align: center; }
.stat-num { font-size: 28px; font-weight: 800; color: var(--orange); display: block; line-height: 1; margin-bottom: 6px; }
.stat-label { font-size: 12px; color: var(--muted); font-weight: 500; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--dark); color: rgba(255,255,255,0.75); padding: 60px 0 0; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-brand .footer-logo { height: 40px; margin-bottom: 16px; filter: brightness(0) invert(1); }
.footer-brand p { font-size: 13px; line-height: 1.7; opacity: 0.7; margin-bottom: 16px; }
.footer-socials { display: flex; gap: 10px; }
.social-link { width: 36px; height: 36px; background: rgba(255,255,255,0.08); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; color: rgba(255,255,255,0.7); transition: all var(--transition); }
.social-link:hover { background: var(--orange); color: #fff; }
.footer-col h5 { font-size: 13px; font-weight: 700; color: #fff; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 16px; }
.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-links a { font-size: 13px; color: rgba(255,255,255,0.65); transition: color var(--transition); }
.footer-links a:hover { color: var(--orange); }
.footer-bottom { padding: 18px 0; text-align: center; font-size: 12px; opacity: 0.55; }

/* ============================================================
   PAGE HEADER (inner pages)
   ============================================================ */
.page-header { background: linear-gradient(135deg, var(--dark) 0%, var(--dark-2) 100%); padding: 36px 0; color: #fff; margin-bottom: 36px; }
.page-header h1 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 13px; opacity: 0.7; }
.breadcrumb a { color: rgba(255,255,255,0.7); }
.breadcrumb a:hover { color: #fff; }
.breadcrumb span { opacity: 0.5; }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 7px; }
.form-control { width: 100%; padding: 11px 16px; border: 1px solid var(--border); border-radius: 7px; font-size: 14px; color: var(--text); background: #fff; outline: none; transition: border-color var(--transition); }
.form-control:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(255,102,0,0.12); }
.form-control::placeholder { color: #aaa; }

/* ============================================================
   ALERT / NOTICE
   ============================================================ */
.alert { padding: 14px 18px; border-radius: 8px; font-size: 13px; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.alert-info { background: #e8f4fd; color: #0066cc; border: 1px solid #b3d7f5; }
.alert-success { background: #eafaf1; color: #22863a; border: 1px solid #b2e4c5; }
.alert-warning { background: #fff8e1; color: #b07800; border: 1px solid #ffe082; }

/* ============================================================
   TABS
   ============================================================ */
.tab-list { display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 24px; }
.tab-btn { padding: 11px 22px; font-size: 14px; font-weight: 600; color: var(--muted); background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all var(--transition); cursor: pointer; }
.tab-btn.active, .tab-btn:hover { color: var(--orange); border-bottom-color: var(--orange); }

/* ============================================================
   CARD LAYOUT (general)
   ============================================================ */
.card { background: #fff; border-radius: var(--radius); border: 1px solid var(--border); overflow: hidden; box-shadow: var(--shadow-sm); }
.card-header { padding: 18px 24px; border-bottom: 1px solid var(--border); }
.card-header h3 { font-size: 16px; font-weight: 700; }
.card-body-pad { padding: 24px; }

/* ============================================================
   BADGES
   ============================================================ */
.badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 700; }
.badge-orange { background: var(--orange-light); color: var(--orange); }
.badge-green { background: #eafaf1; color: #22863a; }
.badge-gray { background: #f0f2f5; color: var(--muted); }

/* ============================================================
   SORT SELECT (shop page)
   ============================================================ */
.sort-select { padding: 9px 14px; border: 1px solid var(--border); border-radius: 7px; font-size: 13px; background: #fff; cursor: pointer; outline: none; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: 200px 1fr; }
  .hero-right { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}

@media (max-width: 768px) {
  .hero-grid { grid-template-columns: 1fr; }
  .side-categories { display: none; }
  .header-top { display: none; }
  .search-form select { display: none; }
  .search-form { max-width: 100%; }
  .stats-bar { grid-template-columns: repeat(2, 1fr); padding: 20px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .promo-banner { flex-direction: column; text-align: center; padding: 24px; }
  .header-main .container { flex-wrap: wrap; height: auto; padding: 10px 20px; gap: 10px; }
  .search-form { order: 3; width: 100%; max-width: 100%; height: 42px; }
  .site-logo img { height: 38px; }
}

@media (max-width: 480px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .header-actions .hdr-btn span { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-banner { padding: 30px 24px; }
  .hero-banner h1 { font-size: 26px; }
}
