/* =======================================================
   City Guides — Clean + Optimized CSS (single source of truth)
   Works with your current HTML structure
======================================================= */

/* ---------- Global overflow safety ---------- */
html,
body {
  overflow-x: hidden;
}

@supports (overflow: clip) {

  html,
  body {
    overflow-x: clip;
  }
}

/* ---------- Theme + base ---------- */
.cg-page {
  --cg-sticky-top: 1rem;

  --cg-accent: #06b6d4;
  --cg-accent-2: #22c55e;
  --cg-purple: #a855f7;

  --cg-text: #0f172a;
  --cg-muted: rgba(15, 23, 42, .70);

  --cg-line: rgba(15, 23, 42, .10);
  --cg-line-2: rgba(15, 23, 42, .14);

  --cg-soft: #f7f8fc;
  --cg-card: #ffffff;

  --r-sm: 14px;
  --r-md: 18px;
  --r-lg: 22px;
  --r-xl: 26px;

  --shadow-1: 0 10px 30px rgba(2, 6, 23, .08);
  --shadow-2: 0 18px 55px rgba(2, 6, 23, .12);
  --shadow-3: 0 28px 90px rgba(2, 6, 23, .16);

  --ring: 0 0 0 4px rgba(6, 182, 212, .18);

  --aside-w: 340px;

  color: var(--cg-text);
  background:
    radial-gradient(900px 520px at 12% 0%, rgba(34, 197, 94, .10), transparent 55%),
    radial-gradient(820px 520px at 90% 10%, rgba(14, 165, 233, .10), transparent 55%),
    linear-gradient(180deg, #f7f8fc 0%, #ffffff 70%);

  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.cg-page *,
.cg-page *::before,
.cg-page *::after {
  box-sizing: border-box;
}

.cg-page :where(a, button, input, select) {
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease, background .15s ease, filter .15s ease;
}

.cg-page a {
  -webkit-tap-highlight-color: transparent;
}

.cg-page a:focus-visible,
.cg-page button:focus-visible,
.cg-page input:focus-visible,
.cg-page select:focus-visible {
  outline: none;
  box-shadow: var(--ring);
}

@media (prefers-reduced-motion: reduce) {

  .cg-page :where(a, button, input, select),
  .cg-post-card,
  .cg-post-media img {
    transition: none !important;
  }
}

/* Your section padding */
.bdo-sec-cityguides {
  padding-top: 0 !important;
}

/* =======================================================
   HERO
======================================================= */
.cg-hero-fw {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  position: relative;
  overflow: hidden;
  padding: clamp(2.2rem, 4vw, 3.8rem) 0;
  border-bottom: 1px solid rgba(15, 23, 42, .06);
  background:
    radial-gradient(900px 520px at 12% 15%, rgba(6, 182, 212, .18), transparent 55%),
    radial-gradient(900px 520px at 85% 10%, rgba(34, 197, 94, .14), transparent 58%),
    linear-gradient(180deg, #ffffff 0%, #f6f8ff 100%);
}

.cg-hero-fw::before {
  content: "";
  position: absolute;
  inset: -120px -120px auto auto;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle at 30% 30%, rgba(168, 85, 247, .18), rgba(168, 85, 247, 0) 60%);
  pointer-events: none;
}

.cg-hero-fw::after {
  content: "";
  position: absolute;
  inset: auto auto -160px -160px;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle at 30% 30%, rgba(6, 182, 212, .20), rgba(6, 182, 212, 0) 60%);
  pointer-events: none;
}

.cg-hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
}

.cg-hero-wrap {
  display: grid;
  grid-template-columns: 1.12fr .88fr;
  gap: clamp(1.1rem, 3.2vw, 2.2rem);
  align-items: center;
}

.cg-hero-copy {
  max-width: 64ch;
  text-align: left;
}

.cg-hero-kicker {
  display: flex;
  align-items: center;
  gap: .7rem;
  flex-wrap: wrap;
  margin-bottom: .85rem;
}

.cg-chip {
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 .9rem;
  border-radius: 999px;
  font-weight: 950;
  letter-spacing: .08em;
  font-size: .78rem;
  color: #0b3b44;
  background: rgba(6, 182, 212, .14);
  border: 1px solid rgba(6, 182, 212, .22);
}

.cg-kicker-text {
  font-weight: 300;
  letter-spacing: .14em;
  font-size: .78rem;
  color: rgba(15, 23, 42, .55);
}

.cg-hero-h1 {
  margin: 0;
  font-weight: 300;
  font-size: clamp(1.95rem, 4vw, 3rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.cg-grad {
  background: linear-gradient(90deg, #22c55e 0%, #06b6d4 45%, #a855f7 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.cg-hero-p {
  margin: 1rem 0 0;
  font-size: clamp(.98rem, 1.2vw, 1.08rem);
  color: var(--cg-muted);
  line-height: 1.55;
  max-width: 62ch;
}

.cg-hero-ctas {
  margin-top: 1.15rem;
  display: flex;
  gap: .7rem;
  flex-wrap: wrap;
}

.cg-btn-primary {
  height: 48px;
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: 0 1.05rem;
  border-radius: 16px;
  font-weight: 950;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(135deg, var(--cg-accent), var(--cg-accent-2));
  box-shadow: 0 16px 38px rgba(6, 182, 212, .18);
}

.cg-btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(.98);
}

.cg-btn-ghost {
  height: 48px;
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: 0 1.05rem;
  border-radius: 16px;
  font-weight: 950;
  color: var(--cg-text);
  text-decoration: none;
  background: rgba(255, 255, 255, .92);
  border: 1px solid var(--cg-line-2);
  box-shadow: 0 10px 26px rgba(2, 6, 23, .08);
}

.cg-btn-ghost:hover {
  border-color: rgba(6, 182, 212, .30);
  background: rgba(6, 182, 212, .06);
}

.cg-hero-media {
  position: relative;
  border-radius: var(--r-lg);
  border: 1px solid var(--cg-line);
  background: rgba(255, 255, 255, .92);
  box-shadow: var(--shadow-3);
  overflow: hidden;
}

.cg-hero-media img {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 11;
  object-fit: cover;
  transform: scale(1.02);
}

.cg-hero-float {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .6rem .8rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, .86);
  border: 1px solid rgba(15, 23, 42, .10);
  box-shadow: 0 14px 28px rgba(2, 6, 23, .10);
  backdrop-filter: blur(10px);
  font-weight: 950;
  color: rgba(15, 23, 42, .86);
}

.cg-hero-float i {
  color: var(--cg-accent);
}

/* =======================================================
   HERO SEARCH OVERLAY
======================================================= */
.cg-hero-overlay {
  position: relative;
  z-index: 20;
  margin-top: clamp(-52px, -3.4vw, -30px);
  margin-bottom: 18px;
}

.cg-hero-overlay-grid {
  display: grid;
  grid-template-columns: var(--aside-w) minmax(0, 1fr);
  gap: 1rem;
  align-items: stretch;
}

.cg-hero-overlay-spacer {
  display: block;
}

.cg-hero-searchbar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .95rem;
  padding: .95rem 1rem;
  border-radius: var(--r-xl);
  backdrop-filter: blur(14px);
  
}

.cg-hero-searchmeta {
  min-width: 220px;
}

.cg-hero-searchmeta .t {
  font-weight: 950;
  font-size: 1.05rem;
  color: #0f172a;
  line-height: 1.1;
}

.cg-hero-searchmeta .m {
  margin-top: .18rem;
  font-weight: 900;
  font-size: .90rem;
  color: rgba(15, 23, 42, .60);
}

.cg-hero-searchform {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .58rem .6rem .58rem .85rem;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, .14);
  background: rgba(247, 248, 252, .86);
}

.cg-hero-searchform:focus-within {
  border-color: rgba(6, 182, 212, .35);
  box-shadow: var(--ring);
}

.cg-hero-searchform i {
  color: rgba(15, 23, 42, .55);
}

.cg-hero-searchform input {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #0f172a;
  font-size: 1rem;
}

.cg-hero-searchbtn {
  height: 44px;
  padding: 0 1rem;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
  font-weight: 950;
  color: #fff;
  white-space: nowrap;
  background: linear-gradient(135deg, var(--cg-accent), var(--cg-accent-2));
  box-shadow: 0 14px 30px rgba(6, 182, 212, .18);
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}

.cg-hero-searchbtn:hover {
  filter: brightness(.98);
  transform: translateY(-1px);
}

/* =======================================================
   MAIN LAYOUT
======================================================= */
.cg-shell {
  padding: clamp(.85rem, 1.5vw, 1.05rem);
}

.cg-main {
  width: 100%;
  display: grid;
  grid-template-columns: var(--aside-w) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

/* =======================================================
   ASIDE / CITY LIST
======================================================= */
.cg-aside {
  width: 100%;
  min-width: 0;
  position: sticky;
  top: var(--cg-sticky-top);
  height: calc(100dvh - var(--cg-sticky-top) - 1rem);
}

/* card */
.cg-card {
  width: 100%;
  height: 100%;
  border-radius: var(--r-lg);
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .72);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-2);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: default;

  /* gradient border layer (inside) */
  position: relative;
  isolation: isolate;
}

.cg-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--r-lg);
  padding: 1px;
  background: linear-gradient(135deg, rgba(34, 211, 238, .35), rgba(167, 139, 250, .30), transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 0;
}

.cg-card>* {
  position: relative;
  z-index: 1;
}

.cg-card-hd {
  padding: .95rem 1rem;
  border-bottom: 1px solid rgba(15, 23, 42, .08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .6rem;

  background: linear-gradient(180deg, rgba(247, 248, 252, .92), rgba(255, 255, 255, .82));
  position: sticky;
  top: 0;
  z-index: 3;
}

.cg-card-hd h3 {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 950;
  display: flex;
  align-items: center;
  gap: .55rem;
}

.cg-card-hd h3 i {
  color: var(--cg-accent);
}

.cg-mini {
  font-size: .86rem;
  color: rgba(15, 23, 42, .60);
  font-weight: 900;
}

.cg-card-bd {
  padding: .9rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  min-width: 0;
  flex: 1 1 auto;
  min-height: 0;
}

/* search sticky below header */
.cg-city-search {
  width: 100%;
  display: flex;
  align-items: center;
  gap: .55rem;
  border: 1px solid rgba(15, 23, 42, .12);
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: .7rem .8rem;
  box-shadow: 0 10px 22px rgba(2, 6, 23, .06);

  position: sticky;
  top: 58px;
  z-index: 2;
}

.cg-city-search:focus-within {
  border-color: rgba(6, 182, 212, .35);
  box-shadow: var(--ring);
}

.cg-city-search i {
  color: rgba(15, 23, 42, .55);
}

.cg-city-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--cg-text);
  font-size: .95rem;
}

.cg-city-list {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: .55rem;
  padding-right: .25rem;

  scrollbar-width: thin;
  scrollbar-color: rgba(15, 23, 42, .25) transparent;
}

.cg-city-list::-webkit-scrollbar {
  width: 10px;
}

.cg-city-list::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, .18);
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: content-box;
}

.cg-city-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .72rem .78rem;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, .08);
  background: rgba(255, 255, 255, .92);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.cg-city-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 4px;
  border-radius: 999px;
  opacity: 0;
  background: linear-gradient(180deg, var(--cg-accent), var(--cg-accent-2));
  transition: opacity .15s ease;
}

.cg-city-item:hover {
  transform: translateY(-1px);
  border-color: rgba(6, 182, 212, .28);
  background: rgba(6, 182, 212, .04);
  box-shadow: 0 12px 24px rgba(2, 6, 23, .08);
}

.cg-city-item.is-active {
  border-color: rgba(6, 182, 212, .50);
  background: linear-gradient(90deg, rgba(6, 182, 212, .12), rgba(34, 197, 94, .06), transparent 78%);
  box-shadow: 0 14px 28px rgba(6, 182, 212, .10);
}

.cg-city-item.is-active::before {
  opacity: 1;
}

.cg-city-left {
  display: flex;
  align-items: center;
  gap: .65rem;
  min-width: 0;
}

.cg-city-avatar {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(15, 23, 42, .04);
  display: grid;
  place-items: center;
  font-weight: 950;
  color: rgba(15, 23, 42, .78);
  overflow: hidden;
  flex: 0 0 auto;
}

.cg-city-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cg-city-avatar.is-all {
  background: rgba(6, 182, 212, .10);
  border-color: rgba(6, 182, 212, .18);
  color: rgba(6, 182, 212, .95);
}

.cg-city-name {
  font-weight: 400;
  color: var(--cg-text);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cg-city-pill {
  flex: 0 0 auto;
  padding: .22rem .58rem;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(15, 23, 42, .04);
  color: rgba(15, 23, 42, .82);
  font-weight: 950;
  font-size: .82rem;
}

/* =======================================================
   RIGHT TOP TOOLBAR
======================================================= */
#posts {
  min-width: 0;
}

.cg-right-top {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .55rem;
  flex-wrap: wrap;
  margin-bottom: .9rem;
  padding: .7rem .8rem;
  border-radius: var(--r-lg);
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 28px rgba(2, 6, 23, .08);
}

.cg-actions {
  display: flex;
  align-items: center;
  gap: .55rem;
}

.cg-actions select {
  height: 42px;
  border-radius: 14px;
  padding: .6rem .75rem;
  border: 1px solid rgba(15, 23, 42, .14);
  background: #fff;
  color: var(--cg-text);
  font-weight: 950;
  outline: none;
}

.cg-link {
  height: 42px;
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: 0 .85rem;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, .14);
  background: #fff;
  font-weight: 950;
  color: var(--cg-text);
  text-decoration: none;
  white-space: nowrap;
}

.cg-link:hover {
  border-color: rgba(6, 182, 212, .28);
}

/* =======================================================
   POSTS GRID — improved design (clean, premium)
======================================================= */
.cg-posts {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 380px));
  justify-content: start;
  gap: 1.05rem;
}

.cg-post-card {
  width: 100%;
  border-radius: var(--r-lg);
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .92);
  box-shadow: var(--shadow-1);
  overflow: hidden;
  transform: translateY(0);
  position: relative;
}

.cg-post-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--r-lg);
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(135deg, rgba(6, 182, 212, .18), rgba(34, 197, 94, .12), transparent 70%);
  transition: opacity .18s ease;
}

.cg-post-card:hover {
  transform: translateY(-3px);
  border-color: rgba(6, 182, 212, .24);
  box-shadow: var(--shadow-2);
}

.cg-post-card:hover::before {
  opacity: 1;
}

.cg-post-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

/* media */
.cg-post-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: rgba(2, 6, 23, .04);
}

.cg-post-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.03);
  transition: transform .35s ease;
}

.cg-post-card:hover .cg-post-media img {
  transform: scale(1.08);
}

/* overlay for readability */
.cg-post-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 90% at 20% 0%, rgba(168, 85, 247, .12), transparent 55%),
    linear-gradient(180deg, rgba(2, 6, 23, 0) 40%, rgba(2, 6, 23, .42) 100%);
  opacity: .70;
  pointer-events: none;
}

/* badge */
.cg-post-badge {
  position: absolute;
  top: .75rem;
  right: .75rem;
  left: auto;
  padding: .34rem .62rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .86);
  border: 1px solid rgba(15, 23, 42, .12);
  color: rgba(15, 23, 42, .88);
  font-weight: 950;
  font-size: .82rem;
  box-shadow: 0 12px 24px rgba(2, 6, 23, .10);
  backdrop-filter: blur(10px);
}

/* body */
.cg-post-body {
  padding: 1rem 1rem 1.05rem;
  display: flex;
  flex-direction: column;
  gap: .55rem;
  min-height: 0;
}

.cg-post-title {
  margin: 0;
  font-size: 1.10rem;
  font-weight: 400;
  line-height: 1.22;
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cg-post-desc {
  margin: 0;
  color: rgba(15, 23, 42, .70);
  font-size: .96rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* meta as chips (uses your existing spans) */
.cg-post-meta {
  margin-top: auto;
  padding-top: .75rem;
  border-top: 1px solid rgba(15, 23, 42, .08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .6rem;
  font-weight: 900;
  font-size: .88rem;
  color: rgba(15, 23, 42, .68);
}

.cg-post-meta>span {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .30rem .60rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, .04);
  border: 1px solid rgba(15, 23, 42, .10);
  font-weight: 300;
}

.cg-post-meta .views {
  background: rgba(6, 182, 212, .08);
  border-color: rgba(6, 182, 212, .18);
}

.cg-post-meta i {
  color: var(--cg-accent);
}

/* read chip */
.cg-post-foot {
  margin-top: .65rem;
  display: flex;
  justify-content: flex-end;
}

.cg-post-read {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  height: 36px;
  padding: 0 .78rem;
  border-radius: 999px;
  border: 1px solid rgba(6, 182, 212, .22);
  background: rgba(6, 182, 212, .08);
  color: rgba(15, 23, 42, .88);
  font-weight: 400;
}

.cg-post-card:hover .cg-post-read {
  background: rgba(6, 182, 212, .12);
  border-color: rgba(6, 182, 212, .28);
}

/* =======================================================
   EMPTY + PAGER
======================================================= */
.cg-empty {
  border-radius: var(--r-md);
  padding: 1.05rem 1rem;
  background: var(--cg-soft);
  border: 1px solid rgba(15, 23, 42, .10);
  display: flex;
  gap: .85rem;
  align-items: flex-start;
}

.cg-empty .ico {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(6, 182, 212, .10);
  border: 1px solid rgba(6, 182, 212, .20);
  flex: 0 0 auto;
}

.cg-pager {
  margin-top: 1.25rem;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.cg-pagebtn {
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 .85rem;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, .14);
  background: #fff;
  font-weight: 950;
  color: var(--cg-text);
  text-decoration: none;
}

.cg-pagebtn:hover {
  border-color: rgba(6, 182, 212, .28);
}

.cg-pagebtn.is-active {
  border-color: rgba(6, 182, 212, .55);
  background: rgba(6, 182, 212, .10);
  box-shadow: 0 10px 22px rgba(6, 182, 212, .10);
}

/* =======================================================
   RESPONSIVE
======================================================= */
@media (max-width: 1100px) {
  .cg-page {
    --aside-w: 300px;
  }

  .cg-hero-overlay-grid {
    grid-template-columns: var(--aside-w) minmax(0, 1fr);
  }

  .cg-main {
    grid-template-columns: var(--aside-w) minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .cg-hero-wrap {
    grid-template-columns: 1fr;
  }

  .cg-hero-overlay-grid {
    grid-template-columns: 1fr;
  }

  .cg-hero-overlay-spacer {
    display: none;
  }

  .cg-hero-searchbar {
    flex-direction: column;
    align-items: stretch;
  }

  .cg-hero-searchmeta {
    min-width: 0;
  }
}

@media (max-width: 860px) {
  .cg-main {
    grid-template-columns: 1fr;
  }

  .cg-aside {
    position: static;
    height: auto;
  }

  .cg-card {
    height: auto;
  }

  .cg-city-list {
    max-height: 360px;
  }

  .cg-city-search {
    position: static;
  }
}

@media (max-width: 560px) {

  .cg-hero-ctas .cg-btn-primary,
  .cg-hero-ctas .cg-btn-ghost {
    width: 100%;
    justify-content: center;
  }

  .cg-actions {
    width: 100%;
    flex-wrap: wrap;
  }

  .cg-actions select,
  .cg-link {
    flex: 1 1 auto;
    justify-content: center;
  }

  .cg-posts {
    grid-template-columns: 1fr;
  }
}

/* ================================
   MOBILE: Cities filter as FAB + Offcanvas
   ================================ */

.cg-filter-fab,
.cg-filter-scrim,
.cg-filter-close {
  display: none;
}

@media (max-width: 880px) {

  /* Floating button */
  .cg-filter-fab {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    position: fixed;
    right: 14px;
    bottom: 150px;
    z-index: 100070;
    padding: 12px 14px;
    border-radius: 999px;
    border: 0;
    cursor: pointer;
    font-weight: 700;
    line-height: 1;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .22);
    background: #111;
    color: #fff;
  }

  .cg-filter-fab i {
    font-size: 18px;
  }

  /* Scrim */
  .cg-filter-scrim {
    display: block;
    position: fixed;
    inset: 0;
    border: 0;
    background: rgba(0, 0, 0, .45);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease;
    z-index: 100060;
  }

  body.cg-filter-open .cg-filter-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  /* Lock scroll when open */
  body.cg-filter-open {
    overflow: hidden;
  }

  /* Sidebar becomes offcanvas */
  .cg-main {
    display: block !important;
  }

  .cg-aside {
    position: fixed;
    top: 0;
    left: 0;
    height: 100dvh;
    height: 100vh;
    width: min(92vw, 360px);
    z-index: 100065;
    transform: translateX(-110%);
    transition: transform .18s ease;
    margin: 0 !important;
  }

  body.cg-filter-open .cg-aside {
    transform: translateX(0);
  }

  /* Panel styling + scroll */
  .cg-aside .cg-card {
    height: 100%;
    overflow: auto;
    border-radius: 0 18px 18px 0;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .22);
  }

  /* Header actions (count + close) */
  .cg-card-hd-actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
  }

  /* Close button */
  .cg-filter-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 0;
    cursor: pointer;
    background: rgba(0, 0, 0, .06);
  }
}

/* =========================================
   MOBILE: POSTS LIST (image left + content right + CTA right)
   Paste AFTER city-guides.css
   ========================================= */
@media (max-width: 768px) {

  /* Turn the grid into a vertical list */
  .cg-posts {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
  }

  /* Card look like screenshot */
  .cg-post-card {
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
    box-shadow: none;
  }

  /* Row layout */
  .cg-post-link {
    display: flex !important;
    gap: 12px;
    padding: 12px;
    align-items: stretch;
  }

  /* Left image */
  .cg-post-media {
    flex: 0 0 112px;
    width: 112px;
    height: 92px;
    border-radius: 12px;
    overflow: hidden;
  }

  .cg-post-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  /* Right content */
  .cg-post-body {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
    padding-right: 108px;
    /* space for the Read Now button */
  }

  .cg-post-title {
    font-size: 16px;
    line-height: 1.25;
    margin: 0 0 6px 0;
    font-weight: 400;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .cg-post-desc {
    margin: 0 0 8px 0;
    font-size: 13px;
    line-height: 1.35;
    color: rgba(0, 0, 0, .68);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .cg-post-meta {
    font-size: 12px;
    color: rgba(0, 0, 0, .55);
    gap: 10px;
  }

  /* Move CTA to the right center like screenshot */
  .cg-post-foot {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    margin: 0;
    padding: 0;
  }

  /* Style CTA as "Read Now" button */
  .cg-post-read {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 10px;
    border: 2px solid rgba(234, 120, 158, .55);
    /* pink-ish outline */
    background: #fff;
    font-size: 12px;
    font-weight: 400;
    color: #e85b8f;
    white-space: nowrap;
  }

  /* Optional: hide trending badge if it crowds */
  /* .cg-post-badge { display: none !important; } */
}

/* ================================
   CITY OVERLAY (City Guides)
   ================================ */
:root {
  --bdo-z-city: 100031;
  /* between nav and fab, similar to search */
}

.bdo-city-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--bdo-z-city);
  display: none;
}

.bdo-city-overlay.open {
  display: block;
}

.bdo-city-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, .58);
  backdrop-filter: blur(7px);
}

.bdo-city-card {
  position: relative;
  width: min(92vw, 560px);
  margin: 10vh auto 0;
  border-radius: 18px;
  padding: 14px;
  background: color-mix(in oklab, var(--card, #fff) 92%, transparent);
  border: 1px solid rgba(148, 163, 184, .30);
  box-shadow: 0 35px 90px rgba(2, 6, 23, .32);
  box-sizing: border-box;
}

.bdo-city-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 6px 10px;
}

.bdo-city-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  color: var(--text, #0f172a);
}

.bdo-city-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px;
}

.bdo-city-search i {
  opacity: .75;
}

.bdo-city-search input {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  height: 48px;
  border-radius: 14px;
  padding: 0 14px;
  border: 1px solid rgba(148, 163, 184, .35);
  background: color-mix(in oklab, var(--bg-surface, #fff) 86%, transparent);
  color: var(--text, #0f172a);
  outline: none;
  font-size: 16px;
}

.bdo-city-search input:focus {
  box-shadow: 0 0 0 6px color-mix(in oklab, var(--primary, #7c3aed) 14%, transparent);
  border-color: color-mix(in oklab, var(--primary, #7c3aed) 45%, transparent);
}

.bdo-city-list {
  margin-top: 6px;
  max-height: min(56vh, 420px);
  overflow: auto;
  display: grid;
  gap: 8px;
  padding: 6px;
}

.bdo-city-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, .22);
  box-shadow: 0 10px 24px rgba(2, 6, 23, .06);
  color: var(--text, #0f172a);
  font-weight: 800;
}

.bdo-city-item.is-active {
  background: color-mix(in oklab, var(--primary, #7c3aed) 10%, white);
  border-color: color-mix(in oklab, var(--primary, #7c3aed) 25%, transparent);
}

.bdo-city-item .l {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.bdo-city-item .av {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 900;
  background: rgba(241, 245, 249, .9);
  border: 1px solid rgba(148, 163, 184, .18);
}

.bdo-city-item .av.is-all {
  background: rgba(124, 58, 237, .10);
  border-color: rgba(124, 58, 237, .18);
}

.bdo-city-hint {
  padding: 6px 10px 2px;
  font-size: 13px;
  color: color-mix(in oklab, var(--text, #0f172a) 65%, transparent);
}

/* Mobile: bottom sheet */
@media (max-width: 900px) {
  .bdo-city-card {
    width: 100%;
    margin: 0;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 18px 18px 0 0;
    padding: 14px 14px calc(14px + env(safe-area-inset-bottom));
  }

  /* Hide FAB rail when cities overlay open (optional) */
  body.city-open .bdo-fab-rail {
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
  }

  .bdo-fab--city {
    background: linear-gradient(135deg, #10b981, #22d3ee);
    color: #fff;
    border-color: rgba(255, 255, 255, .22);
  }
}