/* Tudo Guru custom overrides (safe place for your branding) */

:root{
  /* Palette inspired by the provided Tudo Guru promo image */
  --tg-blue: #0a66c2;      /* headline blue */
  --tg-navy: #0b1b3a;      /* deep UI navy */
  --tg-green: #1f8f4a;     /* "Guru" green */
  --tg-orange: #f36b21;    /* CTA orange */
  --tg-sky: #eaf4ff;       /* light sky background */
  --tg-surface: #ffffff;   /* cards */
  --tg-text: #0b1220;      /* main text */
  --tg-muted: rgba(11,18,32,.72);
  --tg-border: rgba(11,18,32,.10);

  /* App tokens */
  --tg-radius: 18px;
  --tg-shadow: 0 12px 28px rgba(2,6,23,.10);
  --tg-shadow-soft: 0 10px 30px rgba(2,6,23,.06);
}

body{
  background: var(--tg-bg);
}

/* Brand utilities */
.tg-soft-shadow{ box-shadow: 0 10px 30px rgba(2,6,23,.06); }
.tg-chip{ border: 1px solid rgba(15,23,42,.10); }
.tg-card{ transition: transform .12s ease, box-shadow .12s ease; }
.tg-card:hover{ transform: translateY(-2px); box-shadow: 0 10px 25px rgba(0,0,0,.08); }

/* Hero polish if Tailwind CDN is removed */
.tg-hero{
  background: linear-gradient(180deg, rgba(15,23,42,.04), rgba(248,250,252,1) 45%);
}


/* =========================
   ListingHive UI Modernization
   ========================= */

/* Global link color */
a { color: var(--tg-primary); }
a:hover { opacity: .92; }

/* Primary + secondary buttons */
.button--primary,
.hp-button--primary,
.hp-form__button,
input[type="submit"].button--primary {
  background: var(--tg-primary) !important;
  border-color: var(--tg-primary) !important;
  color: #fff !important;
}
.button--primary:hover,
.hp-button--primary:hover {
  filter: brightness(0.95);
}
.button--secondary,
.hp-button--secondary {
  background: #fff !important;
  border-color: rgba(15,23,42,.16) !important;
  color: var(--tg-primary) !important;
}

/* Accent chips/badges (best-effort selectors) */
.hp-listing__category,
.hp-listing__tag,
.hp-field__label {
  border-radius: 999px;
}

/* =========================
   Equal-height listing cards
   ========================= */

/* Make grid items stretch and cards fill height */
.hp-grid__item { display: flex; }
.hp-grid__item > .hp-listing { flex: 1; }

.hp-listing {
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Push footer to bottom even when some fields are missing */
.hp-listing__content {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.hp-listing__footer {
  margin-top: auto;
}

/* Consistent image crop */
.hp-listing__image,
.hp-listing__image img,
.hp-listing__images,
.hp-listing__images img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  overflow: hidden;
}

/* Small modern touch: card rounding + shadow */
.hp-listing {
  border-radius: 18px;
  overflow: hidden;
}
.hp-listing:hover {
  box-shadow: 0 12px 28px rgba(2,6,23,.10);
}

/* Optional: soften section background */
.hp-page__content { background: transparent; }


/* =========================
   App-like polish (desktop + mobile)
   ========================= */

html { scroll-behavior: smooth; }
body { color: #0b1220; }

/* Slightly tighter modern typography */
body, button, input, select, textarea {
  letter-spacing: -0.01em;
}

/* App-like header effect when scrolled */
.tg-scrolled .header,
.tg-scrolled header {
  box-shadow: 0 10px 30px rgba(2,6,23,.08);
}

/* Make page container feel "app-like" */
.hp-page__content,
.site-content {
  padding-bottom: 92px; /* room for bottom nav on mobile */
}

/* =========================
   Sticky search on Listings page
   ========================= */
/* Best-effort selectors: make search form sticky on /listings/ */
body.post-type-archive-hp_listing .hp-search,
body.post-type-archive-hp_listing .hp-search-form,
body.post-type-archive-hp_listing .hp-search__form,
body.post-type-archive-hp_listing .hp-form--search {
  position: sticky;
  top: 76px; /* below header */
  z-index: 20;
  background: rgba(248,250,252,.92);
  backdrop-filter: blur(10px);
  border-radius: 18px;
  padding: 14px;
  border: 1px solid rgba(15,23,42,.08);
}

/* Space after sticky form */
body.post-type-archive-hp_listing .hp-search + * { margin-top: 14px; }

/* =========================
   Bottom navigation (mobile)
   ========================= */
.tg-bottomnav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  padding: 10px 12px env(safe-area-inset-bottom);
  background: rgba(255,255,255,.90);
  backdrop-filter: blur(12px);
  border-top: 1px solid rgba(15,23,42,.08);
  display: none;
}
.tg-bottomnav__inner{
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}
.tg-bottomnav a{
  text-decoration: none !important;
  color: rgba(11,18,32,.72) !important;
  border-radius: 16px;
  padding: 10px 8px;
  display: grid;
  place-items: center;
  gap: 4px;
  transition: transform .12s ease, background .12s ease;
}
.tg-bottomnav a:hover { background: rgba(2,6,23,.04); transform: translateY(-1px); }
.tg-bottomnav a.is-active{
  color: var(--tg-primary) !important;
  background: rgba(34,197,94,.10);
}
.tg-bottomnav .tg-ico{ font-size: 18px; line-height: 1; }
.tg-bottomnav .tg-lbl{ font-size: 11px; font-weight: 700; line-height: 1; }

@media (max-width: 900px){
  .tg-bottomnav{ display: block; }
}

/* =========================
   Modern listing card refinements
   ========================= */
.hp-listing {
  border: 1px solid rgba(15,23,42,.08);
}
.hp-listing__title a{
  font-weight: 800;
}
.hp-listing__details,
.hp-listing__attributes{
  color: rgba(11,18,32,.78);
}

/* Make featured star badge feel modern */
.hp-listing__featured,
.hp-listing__badge,
.hp-badge {
  border-radius: 999px !important;
}

/* Primary accent for key icons */
.hp-icon,
.hp-field__icon {
  color: rgba(11,18,32,.72);
}

/* Buttons: more app-like */
.button--primary,
.hp-button--primary {
  border-radius: 14px !important;
  padding: 12px 14px !important;
}
.button--secondary,
.hp-button--secondary {
  border-radius: 14px !important;
  padding: 12px 14px !important;
}

/* Blog cards (best effort) */
body.blog .hp-post,
body.archive .hp-post,
body.single-post .hp-post {
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(15,23,42,.08);
}

.tg-bottomnav, .tg-bottomnav * { pointer-events: auto; }


/* Footer credit */
.tg-footer-credit{
  text-align:center;
  font-size:12px;
  font-weight:700;
  color: rgba(11,18,32,.55);
  padding: 14px 10px 96px; /* bottom padding leaves room for mobile nav */
}


/* =========================
   Theme skin inspired by promo image
   ========================= */

body{
  background: radial-gradient(1200px 600px at 50% 0%, rgba(10,102,194,.10), rgba(234,244,255,1) 55%) !important;
  color: var(--tg-text);
}

/* Header / top bar: app-like */
.header, header.site-header{
  background: rgba(255,255,255,.86);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--tg-border);
}
.tg-scrolled .header,
.tg-scrolled header{
  box-shadow: var(--tg-shadow-soft);
}

/* Links */
a{ color: var(--tg-blue); }
a:hover{ color: var(--tg-navy); }

/* Primary button = Orange CTA */
.button--primary,
.hp-button--primary,
.hp-form__button,
input[type="submit"].button--primary{
  background: linear-gradient(180deg, #ff7a34, var(--tg-orange)) !important;
  border-color: rgba(243,107,33,.35) !important;
  color: #fff !important;
  border-radius: 14px !important;
  box-shadow: 0 10px 18px rgba(243,107,33,.20);
}
.button--primary:hover,
.hp-button--primary:hover{
  filter: brightness(.98);
  transform: translateY(-1px);
}

/* Secondary button = Navy outline */
.button--secondary,
.hp-button--secondary{
  background: #fff !important;
  border-color: rgba(11,27,58,.20) !important;
  color: var(--tg-navy) !important;
  border-radius: 14px !important;
}

/* Chips/badges */
.hp-badge,
.hp-listing__badge,
.hp-listing__featured{
  border-radius: 999px !important;
  border: 1px solid rgba(10,102,194,.18) !important;
}

/* App cards */
.hp-listing,
.hp-page__content .hp-widget,
.hp-page__content .widget{
  border-radius: var(--tg-radius);
}

/* Listing cards: premium look */
.hp-listing{
  border: 1px solid var(--tg-border);
  background: var(--tg-surface);
  overflow: hidden;
}
.hp-listing:hover{
  box-shadow: var(--tg-shadow);
}
.hp-listing__title a{
  color: var(--tg-navy);
  font-weight: 900;
  letter-spacing: -0.02em;
}
.hp-listing__details,
.hp-listing__attributes{
  color: var(--tg-muted);
}

/* Listing image: consistent crop */
.hp-listing__image,
.hp-listing__image img,
.hp-listing__images,
.hp-listing__images img{
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  overflow: hidden;
}

/* Search module: app-like */
.hp-form--search,
.hp-search-form,
.hp-search__form{
  border-radius: 22px;
  border: 1px solid var(--tg-border);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  box-shadow: var(--tg-shadow-soft);
}

/* Bottom nav: match palette */
.tg-bottomnav{
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px);
}
.tg-bottomnav a.is-active{
  background: rgba(31,143,74,.12);
  color: var(--tg-navy) !important;
}
.tg-bottomnav a:hover{
  background: rgba(10,102,194,.06);
}

/* Footer credit */
.tg-footer-credit{
  color: rgba(11,27,58,.55);
}
