/* RV Motors Site - eBay Motors style */

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #fff;
  color: #111827;
  font-size: 14px;
  line-height: 1.55;
}
a { color: #3665f3; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
h1, h2, h3 { margin: 0; }

.wrap { max-width: 1280px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 880px; }
.page-pad { padding-top: 24px; padding-bottom: 24px; }
.page-title { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 8px; }
.section-title { font-size: 18px; font-weight: 700; margin-bottom: 14px; }
.center { text-align: center; }
.left { text-align: left; }
.muted { color: #707070; }
.small { font-size: 12.5px; }
.tiny { font-size: 11px; }
.strong { font-weight: 700; }
.dark { color: #111827; }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; }
.mt { margin-top: 16px; }
.right { text-align: right; }
.link-blue { color: #3665f3; }

/* ---------- Header ---------- */
.site-header { background: #fff; border-bottom: 1px solid #e5e5e5; position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.utility-bar { border-bottom: 1px solid #f3f4f6; }
.utility-inner { display: flex; justify-content: space-between; align-items: center; height: 32px; font-size: 12px; color: #374151; }
.utility-left { display: flex; gap: 12px; align-items: center; }
.utility-links { display: flex; gap: 16px; }
.utility-links a { color: #374151; }
.main-bar { display: flex; align-items: center; gap: 16px; padding: 12px 16px; }
.logo { display: flex; align-items: flex-end; flex-shrink: 0; }
.logo:hover { text-decoration: none; }
.logo-word { font-size: 32px; font-weight: 800; letter-spacing: -2px; line-height: 1; }
.c-red { color: #e53238; } .c-blue { color: #0064d2; } .c-yellow { color: #f5af02; } .c-green { color: #86b817; }
.logo-sub { margin-left: 6px; font-size: 12px; color: #6b7280; font-weight: 500; }
.shop-cat { font-size: 11px; color: #4b5563; line-height: 1.2; cursor: pointer; flex-shrink: 0; }
.search-form { flex: 1; display: flex; align-items: center; gap: 8px; }
.search-input { flex: 1; height: 40px; padding: 0 16px; border: 2px solid #374151; border-radius: 999px; font-size: 14px; }
.search-input:focus { outline: none; border-color: #3665f3; }
.advanced-link { font-size: 12px; color: #4b5563; flex-shrink: 0; }
.cat-nav { border-top: 1px solid #f3f4f6; }
.cat-nav-inner { display: flex; gap: 24px; height: 36px; align-items: center; font-size: 12px; }
.cat-nav-inner a { color: #374151; }
.cat-nav-inner .deals { color: #e53238; font-weight: 600; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 42px; padding: 0 24px; border-radius: 999px;
  font-size: 14px; font-weight: 600; cursor: pointer; border: none;
  text-decoration: none; transition: background-color .15s ease;
}
.btn:hover { text-decoration: none; }
.btn-blue { background: #3665f3; color: #fff; }
.btn-blue:hover { background: #2b52cd; }
.btn-outline-blue { background: #fff; color: #3665f3; border: 2px solid #3665f3; }
.btn-outline-blue:hover { background: #eef2ff; }
.btn-outline-gray { background: #fff; color: #111827; border: 1px solid #d1d5db; }
.btn-outline-gray:hover { background: #f9fafb; }
.btn-danger { background: #fff; color: #e53238; border: 1px solid #f5c6c6; }
.btn-danger:hover { background: #fdecec; }
.btn-full { width: 100%; height: 48px; font-size: 15px; margin-top: 8px; }
.btn-sm { height: 34px; padding: 0 14px; font-size: 12.5px; }
.btn-row { display: flex; gap: 8px; margin-top: 16px; }

/* ---------- Generic ---------- */
.card { background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; padding: 20px; margin-bottom: 16px; box-shadow: 0 1px 3px rgba(0,0,0,.04); }
.box-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: #6b7280; margin: 0 0 8px; }
.flash { background: #eef7f0; border: 1px solid #cde7d4; color: #065f46; border-radius: 8px; padding: 12px 16px; font-size: 14px; margin: 12px 0; }
.alert-error { color: #e53238; font-weight: 600; font-size: 14px; margin: 8px 0; }
.form-field { margin-bottom: 14px; }
.form-field label { display: block; font-size: 12px; font-weight: 600; color: #4b5563; margin-bottom: 4px; }
.input, .textarea {
  width: 100%; padding: 0 12px; height: 42px; border: 1px solid #d1d5db; border-radius: 8px;
  font-size: 14px; font-family: inherit;
}
.textarea { height: auto; padding: 10px 12px; resize: vertical; }
.input:focus, .textarea:focus { outline: none; border-color: #3665f3; box-shadow: 0 0 0 3px #eef2ff; }
.form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.inner-box { background: #f7f7f7; border-radius: 8px; padding: 12px 16px; }
.inner-card { background: #fff; }
.empty-state { text-align: center; color: #6b7280; padding: 40px; }

/* ---------- Listing page ---------- */
.breadcrumbs { font-size: 12px; color: #6b7280; padding: 12px 16px; }
.breadcrumbs a { color: #6b7280; }
.crumb-here { color: #111827; font-weight: 600; }
.listing-title { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; margin: 4px 0 20px; }
.listing-grid { display: grid; grid-template-columns: 1fr 380px; gap: 32px; }
.gallery-main { position: relative; border: 1px solid #e5e5e5; border-radius: 8px; overflow: hidden; background: #f9fafb; aspect-ratio: 16 / 10; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-counter { position: absolute; bottom: 12px; right: 12px; background: rgba(0,0,0,.6); color: #fff; font-size: 12px; padding: 2px 10px; border-radius: 6px; }
.thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; padding-bottom: 6px; }
.thumb { width: 96px; height: 64px; object-fit: cover; border: 2px solid #e5e5e5; border-radius: 6px; cursor: pointer; flex-shrink: 0; }
.thumb:hover { border-color: #9ca3af; }
.thumb.active { border-color: #3665f3; }
.side-col { display: flex; flex-direction: column; gap: 16px; }
.purchase-box { background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; padding: 24px; box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.purchase-box p { margin: 6px 0; }
.price { font-size: 32px; font-weight: 800; margin: 8px 0 4px; }
.free-ship { color: #058235; font-weight: 700; }
.positive { color: #058235; font-weight: 700; }
.detail-lines { font-size: 12px; color: #4b5563; border-top: 1px solid #f3f4f6; padding-top: 10px; margin-top: 10px; }
.badges { font-size: 12px; color: #4b5563; border-top: 1px solid #f3f4f6; padding-top: 10px; margin-top: 10px; }
.seller-card { background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; padding: 20px; box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.seller-card p { margin: 4px 0; }
.seller-row { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; border: 1px solid #e5e5e5; }
.avatar-big { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 2px solid #f3f4f6; box-shadow: 0 2px 6px rgba(0,0,0,.08); }
.stars { color: #f5af02; letter-spacing: 1px; }
.big-stars { font-size: 20px; }
.small-stars { font-size: 13px; }

/* ---------- Tabs ---------- */
.tabs-section { margin-top: 36px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid #e5e5e5; overflow-x: auto; }
.tab-btn {
  display: inline-block; padding: 12px 20px; font-size: 14px; font-weight: 600; color: #4b5563;
  background: none; border: none; border-bottom: 2px solid transparent; cursor: pointer;
  margin-bottom: -1px; white-space: nowrap; text-decoration: none; font-family: inherit;
}
.tab-btn:hover { color: #111827; text-decoration: none; }
.tab-btn.active { color: #3665f3; border-bottom-color: #3665f3; }
.tab-panel { display: none; padding: 24px 0; max-width: 900px; font-size: 14.5px; color: #374151; }
.tab-panel.active { display: block; }
.tab-panel p { margin: 0 0 14px; }
.specs-table { width: 100%; border-collapse: collapse; font-size: 14px; border: 1px solid #e5e5e5; }
.specs-table td { padding: 10px 16px; }
.specs-table tr:nth-child(odd) { background: #f7f7f7; }
.spec-key { font-weight: 600; color: #374151; width: 33%; border-right: 1px solid #e5e5e5; }
.feedback-item { border-bottom: 1px solid #f3f4f6; padding: 10px 0; }
.feedback-item p { margin: 4px 0; }
.dot-green { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: #058235; }

/* ---------- Modal ---------- */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 100; align-items: center; justify-content: center; padding: 16px; }
.modal-overlay.open { display: flex; }
.modal { background: #fff; border-radius: 12px; padding: 24px; width: 100%; max-width: 440px; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.modal-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; }
.modal-head h3 { font-size: 18px; }
.modal-close { background: none; border: none; font-size: 26px; line-height: 1; cursor: pointer; color: #6b7280; padding: 0 4px; }
.modal-close:hover { color: #111827; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%);
  background: #111827; color: #fff; padding: 10px 22px; border-radius: 999px;
  font-size: 14px; opacity: 0; transition: opacity .3s ease; z-index: 200;
}
.toast.show { opacity: 1; }

/* ---------- Auth ---------- */
.auth-wrap { background: #f7f7f7; min-height: 70vh; padding: 48px 16px; }
.auth-card { background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; box-shadow: 0 4px 12px rgba(0,0,0,.08); max-width: 420px; margin: 0 auto; padding: 32px; }
.auth-title { font-size: 20px; font-weight: 800; margin: 12px 0 4px; }
.auth-card form { margin-top: 20px; }

/* ---------- Browse ---------- */
.browse-layout { display: grid; grid-template-columns: 240px 1fr; gap: 24px; margin-top: 16px; }
.filters { height: fit-content; }
.filter-item { display: flex; gap: 8px; align-items: center; font-size: 14px; color: #374151; padding: 3px 0; cursor: pointer; }
.result-card { display: flex; gap: 16px; background: #fff; border: 1px solid #e5e5e5; border-radius: 10px; padding: 16px; margin-bottom: 12px; transition: box-shadow .15s ease; }
.result-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.result-img { width: 224px; height: 160px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.result-mid { flex: 1; min-width: 0; }
.result-mid p { margin: 4px 0; }
.result-right { text-align: right; flex-shrink: 0; }
.result-price { font-size: 20px; font-weight: 800; color: #111827; margin: 4px 0; }

/* ---------- Seller profile ---------- */
.seller-hero-row { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.seller-hero-mid { flex: 1; min-width: 200px; }
.seller-hero-mid p { margin: 2px 0; }
.verified { color: #3665f3; font-size: 18px; }
.stat-box { background: #f7f7f7; border-radius: 12px; padding: 16px 24px; text-align: center; }
.stat-box p { margin: 0; }
.stat-big { font-size: 30px; font-weight: 800; color: #058235; }
.items-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.item-card { border: 1px solid #e5e5e5; border-radius: 10px; overflow: hidden; transition: box-shadow .15s ease; }
.item-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.1); text-decoration: none; }
.item-card img { width: 100%; height: 140px; object-fit: cover; display: block; }
.item-card-body { padding: 12px; }
.item-card-body p { margin: 2px 0; }

/* ---------- Checkout / confirmation ---------- */
.checkout-grid { display: grid; grid-template-columns: 1fr 360px; gap: 24px; margin-top: 16px; align-items: start; }
.summary-box { height: fit-content; }
.summary-item { display: flex; gap: 12px; margin-bottom: 12px; }
.summary-img { width: 96px; height: 64px; object-fit: cover; border-radius: 6px; border: 1px solid #e5e5e5; }
.summary-lines { border-top: 1px solid #f3f4f6; padding-top: 12px; }
.summary-lines p { display: flex; justify-content: space-between; margin: 6px 0; }
.summary-total { border-top: 1px solid #f3f4f6; padding-top: 10px; font-size: 16px; font-weight: 800; }
.big-check { width: 64px; height: 64px; border-radius: 50%; background: #058235; color: #fff; font-size: 34px; line-height: 64px; margin: 0 auto 16px; }

/* ---------- Admin ---------- */
.admin-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.admin-row { display: flex; gap: 16px; align-items: center; background: #fff; border: 1px solid #e5e5e5; border-radius: 10px; padding: 12px 16px; margin-bottom: 10px; }
.admin-thumb { width: 80px; height: 56px; object-fit: cover; border-radius: 6px; border: 1px solid #e5e5e5; }
.admin-row-mid { flex: 1; min-width: 0; }
.admin-row-mid p { margin: 2px 0; }
.order-head { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.user-row { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 4px; border-bottom: 1px solid #f3f4f6; }
.user-row:last-child { border-bottom: none; }
.user-row p { margin: 0; }
.role-badge { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: #f3f4f6; color: #4b5563; }
.role-admin { background: #eef2ff; color: #3665f3; }

/* ---------- Footer ---------- */
.site-footer { background: #f7f7f7; border-top: 1px solid #e5e5e5; margin-top: 48px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding: 32px 16px; font-size: 12px; color: #4b5563; }
.footer-grid p { margin: 4px 0; }
.f-title { font-weight: 700; color: #1f2937; }
.footer-bottom { border-top: 1px solid #e5e5e5; padding: 14px 0; font-size: 11px; color: #6b7280; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .listing-grid, .checkout-grid { grid-template-columns: 1fr; }
  .browse-layout { grid-template-columns: 1fr; }
  .filters { display: none; }
  .items-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .utility-links, .cat-nav, .shop-cat { display: none; }
  .logo-word { font-size: 26px; }
  .result-card { flex-direction: column; }
  .result-img { width: 100%; height: 180px; }
  .result-right { text-align: left; }
  .items-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .listing-title { font-size: 22px; }
  .price { font-size: 26px; }
  .form-2col { grid-template-columns: 1fr; }
}
