/*
Theme Name: ExaltRide Theme
Theme URI: https://www.exaltride.com/
Author: ExaltRide Team
Description: Custom WordPress theme matching ExaltRide - India's dedicated car accessories marketplace.
Version: 1.2.0
License: Private
Text Domain: exaltride
*/

:root {
  --navy:        #1a237e;
  --yellow:      #f5c518;
  --yellow-dark: #e0b000;
  --white:       #ffffff;
  --bg:          #f5f5f5;
  --border:      #e0e0e0;
  --text:        #212121;
  --muted:       #757575;
  --radius:      6px;
  --font-head:   'Poppins', sans-serif;
  --font-body:   'Inter', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { background: #fff; color: var(--text); font-family: var(--font-body); font-size: 15px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: var(--text); transition: color 0.2s; }
ul, ol { list-style: none; }
h1,h2,h3,h4 { font-family: var(--font-head); font-weight: 700; line-height: 1.25; color: var(--text); }
p { color: var(--muted); line-height: 1.7; margin-bottom: 1rem; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 1.25rem; }

/* =====================
   HEADER - WHITE like main site
   ===================== */
#site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.header-top {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
}

/* Logo */
.header-logo { display: flex; align-items: center; flex-shrink: 0; }
.header-logo img { height: 48px; width: auto; }

/* Car selector */
.car-selector {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  cursor: pointer;
  white-space: nowrap;
  color: var(--text);
  flex-shrink: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.35rem 0.75rem;
}
.car-selector-label { font-size: 0.68rem; color: var(--muted); display: block; line-height: 1; }
.car-selector-value { font-weight: 600; font-size: 0.82rem; color: var(--text); }

/* Search */
.header-search-wrap {
  flex: 1;
  display: flex;
  max-width: 580px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.header-search-input {
  flex: 1;
  padding: 0.65rem 1rem;
  border: none;
  outline: none;
  font-size: 0.9rem;
  font-family: var(--font-body);
  color: var(--text);
  background: #fff;
}
.header-search-input::placeholder { color: #aaa; }
.header-search-btn {
  background: var(--yellow);
  border: none;
  padding: 0 1.5rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}
.header-search-btn:hover { background: var(--yellow-dark); }

/* Deliver to */
.deliver-to {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  flex-shrink: 0;
  color: var(--text);
}
.deliver-to-label { font-size: 0.68rem; color: var(--muted); display: block; line-height: 1; }
.deliver-to-value { font-weight: 600; font-size: 0.82rem; }

/* Header actions */
.header-actions { display: flex; align-items: center; gap: 1.25rem; margin-left: auto; flex-shrink: 0; }
.header-action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: var(--text);
  font-size: 0.68rem;
  cursor: pointer;
  transition: color 0.2s;
  white-space: nowrap;
  text-decoration: none;
}
.header-action-item:hover { color: var(--navy); }
.header-action-item svg { width: 22px; height: 22px; }

/* =====================
   CATEGORY NAV - Clean white like main site
   ===================== */
#category-nav {
  background: #fff;
  border-top: 1px solid var(--border);
}

.category-nav-inner {
  display: flex;
  align-items: stretch;
  overflow-x: auto;
}

.category-nav-inner a {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.8rem 1.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  border-right: 1px solid var(--border);
  transition: background 0.15s, color 0.15s;
  position: relative;
}

.category-nav-inner a:first-child { border-left: 1px solid var(--border); }

.category-nav-inner a:hover {
  background: #f5f5f5;
  color: var(--navy);
}

.nav-arrow { font-size: 0.7rem; color: var(--muted); }

/* Remove any bullets */
.category-nav-inner ul,
.category-nav-inner li { list-style: none !important; padding: 0 !important; margin: 0 !important; }

/* =====================
   BLOG HERO - subtle, not heavy navy
   ===================== */
.blog-hero {
  background: var(--navy);
  padding: 2.5rem 0;
  text-align: center;
}
.blog-hero h1 { color: #fff; font-size: 1.9rem; margin-bottom: 0.4rem; }
.blog-hero p { color: rgba(255,255,255,0.75); font-size: 0.9rem; margin: 0; }

/* =====================
   BLOG LAYOUT
   ===================== */
.blog-main { padding: 2.5rem 0; }

.blog-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2rem;
  align-items: start;
}

/* Featured post card */
.blog-card-featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
  background: #fff;
  transition: box-shadow 0.2s;
}
.blog-card-featured:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.1); }

.blog-card-featured .card-img {
  aspect-ratio: unset;
  min-height: 260px;
  overflow: hidden;
  background: #f5f5f5;
}
.blog-card-featured .card-img img { width: 100%; height: 100%; object-fit: cover; }

.blog-card-featured .card-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Regular post cards grid */
.blog-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.blog-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  transition: box-shadow 0.2s, transform 0.2s;
}
.blog-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.1); transform: translateY(-2px); }

.card-img {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #f5f5f5;
}
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.blog-card:hover .card-img img { transform: scale(1.03); }

.card-body { padding: 1rem 1.1rem 1.2rem; }

.card-category {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--navy);
  background: rgba(26,35,126,0.07);
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
  margin-bottom: 0.6rem;
}

.card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.4;
  margin-bottom: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-title a { color: inherit; }
.card-title a:hover { color: var(--navy); }

.card-excerpt {
  font-size: 0.83rem;
  color: var(--muted);
  margin-bottom: 0.85rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
  padding-top: 0.7rem;
}

.card-read-more { font-weight: 600; color: var(--navy); font-size: 0.8rem; }
.card-read-more:hover { color: #e8400c; }

/* =====================
   SIDEBAR
   ===================== */
.blog-sidebar { display: flex; flex-direction: column; gap: 1.25rem; }

.sidebar-widget { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: #fff; }

.sidebar-widget-title {
  background: var(--navy);
  color: #fff;
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.65rem 1rem;
}

.sidebar-widget-body { padding: 1rem; }

.sidebar-post {
  display: flex;
  gap: 0.75rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border);
}
.sidebar-post:last-child { border: none; padding-bottom: 0; }

.sidebar-post-img { width: 60px; height: 60px; border-radius: 4px; overflow: hidden; flex-shrink: 0; background: #f5f5f5; }
.sidebar-post-img img { width: 100%; height: 100%; object-fit: cover; }

.sidebar-post-title { font-size: 0.82rem; font-weight: 600; color: var(--text); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sidebar-post-title:hover { color: var(--navy); }
.sidebar-post-date { font-size: 0.72rem; color: var(--muted); margin-top: 3px; }

.sidebar-cats li { display: flex; justify-content: space-between; align-items: center; padding: 0.45rem 0; border-bottom: 1px solid var(--border); font-size: 0.85rem; }
.sidebar-cats li:last-child { border: none; }
.sidebar-cats a { color: var(--text); font-weight: 500; }
.sidebar-cats a:hover { color: var(--navy); }
.sidebar-cats .count { background: #f5f5f5; color: var(--muted); font-size: 0.72rem; padding: 0.1rem 0.45rem; border-radius: 50px; }

/* Search form in sidebar */
.sidebar-search { display: flex; gap: 0.5rem; }
.sidebar-search input { flex: 1; padding: 0.5rem 0.75rem; border: 1px solid var(--border); border-radius: var(--radius); font-size: 0.85rem; outline: none; }
.sidebar-search button { background: var(--navy); color: #fff; border: none; padding: 0.5rem 0.85rem; border-radius: var(--radius); font-size: 0.82rem; font-weight: 600; cursor: pointer; }

/* =====================
   SINGLE POST
   ===================== */
.single-hero {
  background: var(--navy);
  padding: 2.5rem 0 2rem;
}
.single-hero .post-cat {
  display: inline-block;
  background: var(--yellow);
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  margin-bottom: 0.85rem;
}
.single-hero h1 { color: #fff; max-width: 780px; font-size: clamp(1.4rem, 3vw, 2rem); }
.single-hero .post-meta { display: flex; gap: 1.5rem; margin-top: 0.85rem; color: rgba(255,255,255,0.65); font-size: 0.82rem; flex-wrap: wrap; }

.single-layout { display: grid; grid-template-columns: 1fr 300px; gap: 2rem; align-items: start; padding: 2.5rem 0; }

.post-content { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 2rem; }
.post-feat-img { border-radius: var(--radius); overflow: hidden; margin-bottom: 1.75rem; aspect-ratio: 16/9; }
.post-feat-img img { width: 100%; height: 100%; object-fit: cover; }

.post-content p { color: #444; font-size: 1rem; line-height: 1.85; }
.post-content h2 { font-size: 1.35rem; margin: 2rem 0 0.6rem; color: var(--navy); }
.post-content h3 { font-size: 1.1rem; margin: 1.5rem 0 0.5rem; }
.post-content ul { list-style: disc; padding-left: 1.5rem; margin-bottom: 1.25rem; color: #444; }
.post-content ol { list-style: decimal; padding-left: 1.5rem; margin-bottom: 1.25rem; color: #444; }
.post-content li { margin-bottom: 0.4rem; }
.post-content blockquote { border-left: 4px solid var(--navy); background: rgba(26,35,126,0.04); padding: 1rem 1.5rem; margin: 1.5rem 0; border-radius: 0 var(--radius) var(--radius) 0; color: var(--navy); font-style: italic; }

.post-tags { margin-top: 1.75rem; padding-top: 1.25rem; border-top: 1px solid var(--border); }
.post-tags a { display: inline-block; background: #f5f5f5; color: var(--muted); font-size: 0.78rem; padding: 0.25rem 0.65rem; border-radius: 50px; margin: 0 0.25rem 0.25rem 0; border: 1px solid var(--border); }
.post-tags a:hover { background: var(--navy); color: #fff; border-color: var(--navy); }

/* =====================
   PAGINATION
   ===================== */
.blog-pagination { display: flex; align-items: center; justify-content: center; gap: 0.4rem; padding: 2rem 0; flex-wrap: wrap; }
.blog-pagination a, .blog-pagination span { display: flex; align-items: center; justify-content: center; min-width: 38px; height: 38px; padding: 0 0.5rem; border-radius: var(--radius); font-size: 0.875rem; font-weight: 600; border: 1.5px solid var(--border); color: var(--text); transition: all 0.2s; }
.blog-pagination a:hover { border-color: var(--navy); color: var(--navy); }
.blog-pagination .current { background: var(--navy); color: #fff; border-color: var(--navy); }

/* =====================
   FOOTER
   ===================== */
#site-footer { background: var(--navy); color: rgba(255,255,255,0.75); padding: 3rem 0 1.5rem; }
.footer-grid { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 2.5rem; margin-bottom: 2.5rem; }
.footer-logo { font-family: var(--font-head); font-size: 1.4rem; font-weight: 800; color: #fff; }
.footer-logo span { color: var(--yellow); }
.footer-brand p { color: rgba(255,255,255,0.6); font-size: 0.85rem; margin-top: 0.75rem; max-width: 260px; }
.footer-col h4 { color: #fff; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 1rem; }
.footer-col ul li { margin-bottom: 0.5rem; }
.footer-col ul a { color: rgba(255,255,255,0.6); font-size: 0.85rem; }
.footer-col ul a:hover { color: var(--yellow); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 1.25rem; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem; }
.footer-bottom p { color: rgba(255,255,255,0.5); font-size: 0.8rem; margin: 0; }

/* =====================
   RESPONSIVE
   ===================== */
@media (max-width: 1024px) {
  .blog-layout, .single-layout { grid-template-columns: 1fr; }
  .blog-card-featured { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .car-selector, .deliver-to { display: none; }
  .header-top { flex-wrap: wrap; }
  .header-search-wrap { flex: 0 0 100%; order: 3; }
  .footer-grid { grid-template-columns: 1fr; }
  .category-nav-inner { overflow-x: auto; -webkit-overflow-scrolling: touch; }
}

/* =====================
   LOGO SIZE FIX
   ===================== */
.header-logo img,
.custom-logo { 
  height: 36px !important; 
  width: auto !important; 
}

/* =====================
   NAV FULL WIDTH
   ===================== */
#category-nav { width: 100%; }

.category-nav-inner {
  display: flex !important;
  width: 100% !important;
  justify-content: space-between !important;
}

.category-nav-inner a {
  flex: 1 !important;
  justify-content: center !important;
  text-align: center !important;
  border-right: 1px solid var(--border) !important;
}

.category-nav-inner a:last-child {
  border-right: none !important;
}

/* =====================
   CLEAN HEADER - Logo + Search only
   ===================== */
.header-top {
  display: flex !important;
  align-items: center !important;
  gap: 1.5rem !important;
  padding: 0.85rem 0 !important;
  flex-wrap: nowrap !important;
}

.header-logo {
  flex-shrink: 0 !important;
}

.header-search-wrap {
  flex: 1 !important;
  max-width: 100% !important;
  display: flex !important;
  border: 1.5px solid var(--border) !important;
  border-radius: var(--radius) !important;
  overflow: hidden !important;
}

.header-search-input {
  flex: 1 !important;
  padding: 0.65rem 1rem !important;
  border: none !important;
  outline: none !important;
  font-size: 0.9rem !important;
  font-family: var(--font-body) !important;
}

.header-search-btn {
  background: var(--yellow) !important;
  border: none !important;
  padding: 0 1.75rem !important;
  font-weight: 700 !important;
  font-size: 0.9rem !important;
  color: var(--text) !important;
  cursor: pointer !important;
  font-family: var(--font-head) !important;
}

.header-search-btn:hover {
  background: var(--yellow-dark) !important;
}

/* =====================
   FOOTER - MATCH MAIN SITE
   ===================== */
#site-footer {
  background: var(--navy) !important;
  color: rgba(255,255,255,0.75);
  padding: 3.5rem 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr repeat(3, 1fr);
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-brand img,
.footer-brand .custom-logo { height: 50px !important; width: auto !important; }

.footer-tagline {
  color: rgba(255,255,255,0.5) !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.1em !important;
  margin: 0.5rem 0 0.4rem !important;
}

.footer-desc {
  color: rgba(255,255,255,0.6) !important;
  font-size: 0.85rem !important;
  line-height: 1.6 !important;
  max-width: 260px !important;
  margin: 0 !important;
}

.footer-col h4 {
  color: var(--yellow) !important;
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  margin-bottom: 1.1rem !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

.footer-col ul li { margin-bottom: 0.55rem !important; }

.footer-col ul a {
  color: rgba(255,255,255,0.65) !important;
  font-size: 0.875rem !important;
  transition: color 0.2s !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.4rem !important;
}

.footer-col ul a:hover { color: #fff !important; }

.footer-contact-icon { font-size: 0.9rem; }

/* Footer bottom */
.footer-bottom {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 1.25rem 0 !important;
  flex-wrap: wrap !important;
  gap: 1rem !important;
  border-top: none !important;
}

.footer-bottom p {
  color: rgba(255,255,255,0.5) !important;
  font-size: 0.82rem !important;
  margin: 0 !important;
}

/* Social icons */
.footer-socials { display: flex; align-items: center; gap: 0.6rem; }

.social-icon {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 34px !important;
  height: 34px !important;
  border-radius: 50% !important;
  background: rgba(255,255,255,0.1) !important;
  color: rgba(255,255,255,0.75) !important;
  transition: background 0.2s, color 0.2s !important;
}

.social-icon:hover {
  background: var(--yellow) !important;
  color: var(--navy) !important;
}

@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
}
