/**
 * MCI Guides - rand_guides / guides shortcode
 * Layout: 1 featured (large) + small cards
 * Badge from blog taxonomy
 */

.mci-guides-empty {
  padding: 1.5rem;
  text-align: center;
  color: #666;
  background: #f5f5f5;
  border-radius: 4px;
}

/* Guides grid - featured left, small right */
.mci-guides-grid.guides-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  gap: 1.5rem;
  max-width: 100%;
  padding: 0.5rem;
}

@media (min-width: 768px) {
  .mci-guides-grid.guides-grid {
    grid-template-columns: 1.2fr 1fr;
    grid-template-rows: 1fr 1fr;
    grid-auto-flow: column;
    gap: 1.25rem;
  }
}

/* Guide card */
.guide-card {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
}

.guide-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

/* Featured spans both rows on desktop (homepage: 3 cards only) */
@media (min-width: 768px) {
  .mci-guides-grid.guides-grid:not(.mci-guide-archive-grid) .guide-featured {
    grid-row: 1 / -1;
  }
}

/* Photo area */
.guide-card .guide-photo {
  position: relative;
  overflow: hidden;
}

.guide-featured .guide-photo {
  aspect-ratio: 600 / 280;
}

.guide-small .guide-photo {
  aspect-ratio: 400 / 160;
}

.guide-card .guide-photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.guide-card:hover .guide-photo-img {
  transform: scale(1.05);
}

.guide-card .guide-photo-bg {
  width: 100%;
  height: 100%;
  display: block;
}

.guide-card .guide-photo-bg svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.guide-card .guide-photo-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4) 0%, transparent 50%);
  pointer-events: none;
}

/* Category badge */
.guide-card .guide-category {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
}

.guide-card .guide-category.cat-road-trips { background: #2A6A4A; }
.guide-card .guide-category.cat-food-drink,
.guide-card .guide-category.cat-food { background: #6A4A2A; }
.guide-card .guide-category.cat-hidden-gems { background: #3A5A8A; }

.guide-card .guide-featured-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, #c9a227, #a67c00);
  box-shadow: 0 2px 8px rgba(201, 162, 39, 0.4);
}

/* Body */
.guide-card .guide-body {
  padding: 1.25rem 1.25rem 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.guide-card .guide-title {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  color: #1a1a1a;
  letter-spacing: -0.01em;
}

.guide-featured .guide-title {
  font-size: 1.45rem;
}

.guide-type-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
}

.guide-type-pill {
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.guide-card .guide-excerpt {
  font-size: 0.9rem;
  line-height: 1.5;
  color: #4b5563;
  margin-top: 0.25rem;
  flex: 1;
}

.guide-card .guide-link {
  display: inline-flex;
  align-items: center;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #2A6A4A;
  text-decoration: none;
  transition: color 0.2s;
}

.guide-card .guide-link:hover {
  color: #1a4a3a;
}

/* Guide archive - filter buttons (desktop) + dropdown (mobile) */
.mci-guide-filter-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  align-items: center;
  padding: 1.5rem 0;
}

.mci-guide-filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.mci-guide-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #4a4a4a;
  background: #fff;
  padding: 0.625rem 1.5rem;
  border-radius: 24px;
  text-decoration: none;
  border: 1.5px solid #e0e0e0;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.mci-guide-filter-btn:hover {
  color: #1e4a62;
  border-color: #1e4a62;
  background: #f8fafb;
}

.mci-guide-filter-btn.active {
  color: #fff;
  background: #1e4a62;
  border-color: #1e4a62;
  font-weight: 700;
}

.mci-guide-filter-select-wrap {
  display: none;
}

@media (max-width: 767px) {
  .mci-guide-filter-buttons {
    display: none;
  }
  .mci-guide-filter-select-wrap {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
  }
  .mci-guide-filter-select {
    width: 100%;
    font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #4a4a4a;
    background: #fff;
    padding: 0.625rem 1rem;
    border-radius: 24px;
    border: 1.5px solid #e0e0e0;
    appearance: auto;
    cursor: pointer;
  }
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Guide archive - grid: 1 featured (large) + small cards, 2 columns (match homepage) */
.mci-guide-archive .mci-guides-grid.mci-guide-archive-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-auto-flow: row;
  grid-auto-rows: auto;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .mci-guide-archive .mci-guides-grid.mci-guide-archive-grid {
    grid-template-columns: 1.2fr 1fr;
    grid-template-rows: auto auto;
    gap: 1.25rem;
  }

  /* Featured spans only first 2 rows, not all */
  .mci-guide-archive .mci-guides-grid .guide-featured {
    grid-row: 1 / 3;
  }
}

/* Guide archive - ad cell spans full width */
.mci-guide-archive .mci-guide-ad-cell {
  grid-column: 1 / -1;
}

.mci-guide-archive .mci-guide-ad {
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px dashed #dee2e6;
}

.mci-guide-archive .mci-guide-ad iframe,
.mci-guide-archive .mci-guide-ad ins {
  max-width: 100%;
}

/* Guide archive pagination - match people pagination style */
.mci-guide-pagination {
  margin-top: 2.5rem;
  padding: 1rem 0;
}

.mci-guide-pagination-inner {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mci-guide-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 0.75rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #2E4A7A;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.mci-guide-pagination .page-numbers:hover {
  background: #f3f4f6;
  border-color: #2E4A7A;
  color: #1a3355;
}

.mci-guide-pagination .page-numbers.current {
  background: #2E4A7A;
  border-color: #2E4A7A;
  color: #fff;
}

.mci-guide-pagination .page-numbers.dots {
  border: none;
  background: transparent;
  cursor: default;
}

.mci-guide-pagination ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.mci-guide-pagination ul li {
  margin: 0;
}
.mci-guide-pagination ul li::before {
  display:none !important;
}
