body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: #f3f4f6;
}

.aiLayout {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px;
  gap: 20px;
}

.aiLeft, .aiRight {
  background: #ffffff;
  border-radius: 10px;
  padding: 18px 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.aiLeft {
  width: 360px;
}

.aiRight {
    flex: 1;
    background: #ffffff;
    border-radius: 10px;
    padding: 18px 22px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

/* Desktop / large screens only */
@media (min-width: 900px) {
    .aiRight {
        min-width: 420px;
    }
}

.aiTitle {
  margin: 0;
  font-size: 20px;
  font-weight: bold;
  color: #111827;
}

.aiSubtitle {
  margin: 4px 0 16px;
  font-size: 13px;
  color: #6b7280;
}

.aiFilterBlock {
  margin-bottom: 14px;
}

.aiFilterLabel {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}

.aiChipRow {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top:10px;
   background: #eef6ff;
    border: 1px solid #d4e4ff;
	    padding: 10px
}

.aiChipClear{
    background:#f3f4f6;
    color:#374151;
    border:1px dashed #d1d5db;
}
.aiChipClear:hover{
    background:#fee2e2;
    color:#991b1b;
}


.aiChip {
  border-radius: 999px;
  border: 1px solid #d1d5db;
  background: #f9fafb;
  padding: 5px 10px;
  font-size: 12px;
  cursor: pointer;
  color: #374151;
}

.aiChip.selectedChip {
  background: #1d4ed8;
  color: #ffffff;
  border-color: #1d4ed8;
}

.aiSelect {
  width: 100%;
  padding: 6px 8px;
  font-size: 13px;
  border-radius: 6px;
  border: 1px solid #d1d5db;
}

.aiInput {
  border-radius: 6px;
  border: 1px solid #d1d5db;
  padding: 6px 8px;
  font-size: 13px;
  flex: 1;
}

.aiBudgetRow {
  display: flex;
  align-items: center;
  gap: 4px;
}

.aiBudgetRow span {
  font-size: 13px;
  color: #4b5563;
}

.aiFilterActions {
  margin-top: 10px;
}

.aiPrimaryBtn {
  background: #1d4ed8;
  color: #ffffff;
  border: none;
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 14px;
  cursor: pointer;
}

.aiPrimaryBtn:hover {
  background: #1e40af;
}

.aiError {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: #b91c1c;
}

.aiDebug {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  color: #6b7280;
}

/* RIGHT PANEL */

.aiChatPanel {
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  padding: 10px 12px;
  margin-bottom: 14px;
  background: #f9fafb;
}

.aiChatHeader {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}

.aiAvatar {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: #1d4ed8;
  color: #ffffff;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.aiChatTitle {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.aiChatSubtitle {
  font-size: 12px;
  color: #6b7280;
}

.aiChatBody {
  font-size: 13px;
  color: #374151;
}

/* RESULTS */

.aiResultsPanel {
  margin-top: 6px;
}

.aiResultsHeader {
  margin-bottom: 10px;
}

.aiResultsCount {
  font-weight: 600;
  font-size: 13px;
  color: #111827;
}

.schoolCard {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #e5e7eb;
}

.schoolPhoto {
  position: relative;
  width: 110px;
  min-width: 110px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  background: #e5e7eb;
}

.schoolPhoto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fitBadge {
  position: absolute;
  left: 6px;
  bottom: 6px;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 999px;
  color: #ffffff;
}

.fitBest {
  background: #15803d;
}

.fitGood {
  background: #0369a1;
}

.fitOk {
  background: #92400e;
}

.schoolInfo {
  flex: 1;
}

.schoolName {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.schoolAddress {
  font-size: 12px;
  color: #6b7280;
  margin: 2px 0 4px;
}

.schoolMeta {
  font-size: 11px;
  color: #4b5563;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 4px;
}

.schoolMeta .metaItem strong {
  font-weight: 600;
}

.schoolFacilities {
  font-size: 11px;
  color: #4b5563;
  margin-bottom: 3px;
}

.schoolWhyFit {
  font-size: 11px;
  color: #111827;
}

/* Responsive-ish */
@media (max-width: 960px) {
  .aiLayout {
    flex-direction: column;
  }
  .aiLeft, .aiRight {
    width: auto;
  }
}
.aiChip-active {
  background:#2563eb;
  color:#fff;
  border-color:#2563eb;
}
.aiBadge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 14px;
    font-size: 12px;
    background: #eef7ff;
    color: #075985;
    border: 1px solid #93c5fd;
}

.aiBadge-soft {
    background: #f0f9ff;
    border-color: #7dd3fc;
    color: #0c4a6e;
}
/* Card layout */
.schoolCard {
  display: flex;
  gap: 16px;
  padding: 16px 18px;
  margin-bottom: 14px;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  background: #ffffff;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

.schoolCard:hover {
  transform: translateY(-2px);
  border-color: #bfdbfe;
  box-shadow: 0 10px 25px rgba(30, 64, 175, 0.16);
}

/* Photo area */
.schoolPhoto {
  position: relative;
  flex: 0 0 120px;
}

.schoolPhoto img {
  width: 120px;
  height: 90px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #f3f4f6;
}

/* Fit badge (Perfect / Good / Consider) */
.fitBadge {
  position: absolute;
  left: 10px;
  bottom: 8px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  background: #e5e7eb;
  color: #374151;
}

.fitBest {
  background: #dcfce7;
  color: #166534;
}

.fitGood {
  background: #e0f2fe;
  color: #075985;
}

.fitOk {
  background: #fef3c7;
  color: #92400e;
}

/* Right side info block */
.schoolInfo {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Top row: title + buttons */
.schoolHeaderRow {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.schoolTitleBlock {
  flex: 1;
}

.schoolName {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
  margin-bottom: 4px;
}

/* Small tags under title */
.schoolTags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid transparent;
}

.tag-type {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}

.tag-verified {
  background: #ecfdf3;
  border-color: #bbf7d0;
  color: #15803d;
}

.tag-govt {
  background: #fef3c7;
  border-color: #fde68a;
  color: #92400e;
}

/* View details button */
.schoolActions {
  flex: 0 0 auto;
}

.viewDetailsBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid #1d4ed8;
  background: #1d4ed8;
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.viewDetailsBtn:hover {
  background: #1e40af;
  border-color: #1e40af;
}

/* Address */
.schoolAddress {
  margin-top: 4px;
  font-size: 13px;
  color: #4b5563;
}

/* Meta row */
.schoolMeta {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: 12px;
  color: #4b5563;
}

.metaItem strong {
  font-weight: 600;
}

.metaIcon {
  margin-right: 4px;
  font-size: 13px;
}

/* Facilities & why fit */
.schoolFacilities {
  margin-top: 6px;
  font-size: 12px;
  color: #6b7280;
}

.schoolWhyFit {
  margin-top: 6px;
  font-size: 12px;
  color: #0f172a;
  background: #f9fafb;
  border-radius: 10px;
  padding: 6px 9px;
}

/* Extra badge (serves other classes) */
.extraBadge {
  margin-top: 6px;
}

.aiBadge {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
}

.aiBadge-soft {
  background: #eef2ff;
  color: #4f46e5;
}
/* Summary container */
.aiFilterSummary {
   
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 18px;
}

/* Main line of summary text */
.aiFilterSummaryText {
    font-size: 14px;
    color: #1e3a8a;
    margin-bottom: 8px;
    font-weight: 500;
}

/* Chips row – horizontal scroll */
.aiFilterChips {
    display: flex;
    flex-wrap: nowrap;              /* 🔴 stop wrapping */
    gap: 8px;
    overflow-x: auto;               /* ✅ horizontal scroll */
    overflow-y: hidden;
    white-space: nowrap;
    padding-bottom: 6px;
   
	
	/* hide scrollbar */
    scrollbar-width: none;          /* Firefox */
    -ms-overflow-style: none;       /* IE / Edge legacy */
    -webkit-overflow-scrolling: touch;
}

/* Hide scrollbar (optional, mobile friendly) */
.aiFilterChips::-webkit-scrollbar {
    height: 6px;
}
.aiFilterChips::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.15);
    border-radius: 4px;
}


/* Individual chips */
.filterChip {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 12px;
    color: #374151;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Small icons inside the chips */
.filterChipIcon {
    font-size: 14px;
}
/* ===== MOBILE COMPACT MODE ===== */
@media (max-width: 768px) {

  /* Overall layout: filters on top, results below */
  .aiLayout {
    display: block;              /* instead of grid/2-column */
  }

  .aiFiltersPanel {
    margin-bottom: 10px;
    position: static;
    max-height: none;
    box-shadow: none;
  }

  .aiResultsPanel {
    padding: 8px;
  }

  .aiChatPanel {
    padding: 10px 10px 8px 10px;
  }

  .aiChatTitle {
    font-size: 14px;
  }

  .aiChatSubtitle {
    font-size: 11px;
    line-height: 1.3;
  }

  .aiAvatar {
    
    height: 24px;
    font-size: 12px;
  }

  .aiResultsHeader .aiResultsCount {
    font-size: 13px;
  }

  /* Filter summary line under filters */
  .aiFilterSummary {
    padding: 8px 10px;
    font-size: 11px;
  }
}
@media (max-width: 768px) {

  .schoolCard {
    display: flex;
    gap: 8px;
    padding: 8px;
    border-radius: 10px;
    margin-bottom: 8px;
  }

  .schoolPhoto {
    flex: 0 0 80px;
  }

  .schoolPhoto img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 10px;
  }

  .fitBadge {
    font-size: 10px;
    padding: 2px 6px;
    bottom: 4px;
    left: 4px;
  }

  .schoolInfo {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
  }

  .schoolHeaderRow {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: flex-start;
  }

  .schoolTitleBlock {
    width: 100%;
  }

  .schoolName {
    font-size: 14px;
    line-height: 1.2;
    font-weight: 600;
  }

  .schoolTags {
    margin-top: 2px;
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
  }

  .tag {
    font-size: 10px;
    padding: 1px 5px;
    border-radius: 999px;
  }

  .schoolActions {
    margin-top: 4px;
  }

  .viewDetailsBtn {
    font-size: 11px;
    padding: 4px 8px;
  }

  .schoolAddress {
    font-size: 11px;
    line-height: 1.3;
  }

  .schoolMeta {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 6px;
    font-size: 11px;
    margin-top: 3px;
  }

  .metaItem {
    display: flex;
    align-items: center;
  }

  .metaIcon {
    margin-right: 3px;
    font-size: 12px;
  }

  .schoolFacilities,
  .schoolWhyFit {
    font-size: 11px;
    line-height: 1.25;
    margin-top: 2px;
    max-height: 38px;       /* keep it compact */
    overflow: hidden;
  }

  .extraBadge {
    margin-top: 4px;
  }

  .aiBadge.aiBadge-soft {
    font-size: 10px;
    padding: 2px 6px;
  }
}
@media (max-width: 480px) {
  .schoolCard {
    padding: 6px;
  }

  .schoolPhoto {
    flex: 0 0 64px;
  }

  .schoolPhoto img {
    width: 64px;
    height: 64px;
  }

  .schoolName {
    font-size: 13px;
  }

  .schoolMeta {
    font-size: 10px;
  }

  .schoolFacilities,
  .schoolWhyFit {
    max-height: 32px;
  }
}
/* =========================
   MOBILE LAYOUT (<= 768px)
   ========================= */
@media (max-width: 768px) {

  /* Overall page */
  .aiPage {
    padding: 8px;
  }

  /* Two-column layout → single column */
  .aiLayout {
    display: block;
  }

  .aiFiltersPanel,
  .aiResultsPanel {
    width: 100%;
    max-width: 100%;
    margin: 0 0 10px 0;
  }

  /* Card should never be wider than screen */
  .schoolCard {
    flex-direction: row;
    align-items: flex-start;
    padding: 10px;
    margin-bottom: 10px;
    max-width: 100%;
    box-sizing: border-box;
  }

  /* Photo smaller on mobile */
  .schoolPhoto {
    flex: 0 0 80px;
    width: 80px;
    margin-right: 8px;
  }

  .schoolPhoto img {
    width: 80px;
    height: 60px;
    object-fit: cover;
  }

  .fitBadge {
    font-size: 10px;
    padding: 2px 6px;
  }

  /* Info area uses the rest of the width */
  .schoolInfo {
    padding: 0;
  }

  /* Header row: name + tags + button stacked */
  .schoolHeaderRow {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .schoolName {
    font-size: 14px;
    line-height: 1.3;
  }

  .schoolTags {
    flex-wrap: wrap;
    gap: 4px;
  }

  .tag {
    font-size: 10px;
    padding: 2px 6px;
  }

  .schoolActions {
    margin-top: 4px;
    width: 100%;
  }

  .viewDetailsBtn {
    display: inline-block;
    font-size: 11px;
    padding: 5px 10px;
  }

  /* Meta row wraps nicely */
  .schoolMeta {
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
    font-size: 11px;
  }

  .metaItem {
    margin-right: 4px;
  }

  .schoolAddress,
  .schoolFacilities,
  .schoolWhyFit {
    font-size: 11px;
    line-height: 1.4;
  }

  .extraBadge .aiBadge {
    font-size: 10px;
    padding: 2px 6px;
  }

  /* AI summary badges row */
  .aiFilterSummary {
    flex-wrap: wrap;
    gap: 4px;
  }

  .aiSummaryChip {
    font-size: 11px;
    padding: 4px 6px;
  }

  /* Remove any accidental horizontal scroll */
  body {
    overflow-x: hidden;
  }
}
@media (max-width: 768px) {
  .pageWrap {
    max-width: 100%;
  }
}
/* ===== MOBILE FIX: prevent horizontal scroll & compact cards ===== */
/* ===== SUPER-SAFE MOBILE LAYOUT (no horizontal overflow) ===== */
@media (max-width: 600px) {

  html,
  body {
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;       /* no horizontal scroll */
  }

  /* Generic clamp: no child wider than the viewport */
  body * {
    box-sizing: border-box;
    max-width: 100% !important;
  }

  /* Main layout: single column, full width */
  .pageWrapper,
  .aiLayout,
  .aiFiltersColumn,
  .aiResultsColumn,
  .aiChatPanel,
  .aiResultsPanel {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  /* School card compact layout */
  .schoolCard {
    display: flex;
    align-items: flex-start;
    padding: 10px;
    margin: 8px 0;
    border-radius: 10px;
  }

  .schoolPhoto {
    flex: 0 0 80px;
    margin-right: 8px;
  }

  .schoolPhoto img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
  }

  .schoolInfo {
    flex: 1 1 auto;
  }

  .schoolHeaderRow {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }

  .schoolName {
    font-size: 14px;
    line-height: 1.3;
  }

  .schoolActions {
    margin-left: auto;
  }

  .viewDetailsBtn {
    padding: 4px 10px;
    font-size: 12px;
  }

  .schoolMeta {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 6px;
    font-size: 11px;
  }

  .metaItem {
    margin-right: 0;
  }

  .aiSummaryPills {
    flex-wrap: wrap;
    gap: 4px;
  }

  .aiSummaryPill {
    font-size: 11px;
    padding: 4px 6px;
  }
}
@media (max-width: 768px) {
    .aiLayout {
        flex-direction: column;
        gap: 12px;
    }

    .aiLeft,
    .aiRight {
        width: 100%;
        max-width: 100%;
        min-width: 0;          /* override any desktop min-width */
        box-sizing: border-box;
    }

    .schoolCard {
        flex-direction: row;
        align-items: flex-start;
    }

    .schoolPhoto {
        width: 28%;
        min-width: 90px;
        margin-right: 8px;
    }

    .schoolInfo {
        width: 72%;
    }
}
/* =========================================
   Compact mobile tweaks
   ========================================= */
@media (max-width: 600px) {

  /* Remove extra gutters */
  body {
    padding: 0;
  }

  .aiLayout {
    padding: 6px 4px;
  }

  .aiRight {
    padding: 8px 4px 14px 4px;   /* smaller side padding */
  }

  .aiResultsPanel {
    padding: 6px 4px 10px 4px;   /* card block almost edge-to-edge */
  }

  /* School card: tighter and full-width look */
  .schoolCard {
    margin: 0 0 10px 0;          /* no left/right margin */
    padding: 10px 10px 12px 10px;
    border-radius: 10px;
  }

  /* Photo narrower so text gets more width */
  .schoolPhoto {
    width: 72px;
    flex: 0 0 72px;
  }

  .schoolInfo {
    padding-left: 10px;
  }

  /* Meta row wraps nicely on 2–3 lines */
  .schoolMeta {
    flex-wrap: wrap;
    row-gap: 2px;
  }

  .schoolMeta .metaItem {
    margin-right: 8px;
	 margin-bottom: 6px;
    font-size: 11px;
  }

  /* “Why fit” + parent rating text – keep inside box nicely */
  .schoolWhyFit {
    margin-top: 6px;
    font-size: 11px;
    line-height: 1.4;
  }

  /* Extra badge line */
  .extraBadge {
    margin-top: 4px;
  }
}
.schoolCard--active{
  box-shadow:0 0 0 2px #2563eb33, 0 12px 30px rgba(15,23,42,0.12);
  border-color:#2563eb;
}
/* Marker legend colors */
.legendDot-school {
  background: #2563eb; /* blue */
}
.legendDot-user {
  background: #dc2626; /* red */
}

/* Highlighted card when marker clicked */
.schoolCard.mapHighlight {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.35);
}

  /* autocomplete wrapper */
  .aiCityAutoWrap {
    position: relative;
  }
  .aiCityAutoSuggestions {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 20;
    background: #f8fbff;
    border-radius: 8px;
    border: 1px solid #cbd5e1;        /* darker border */
    margin-top: 2px;
    max-height: 180px;
    overflow-y: auto;
     box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    display: none;
  }
  .aiCityAutoItem {
    padding: 6px 9px;
    font-size: 13px;
    cursor: pointer;
	 color: #1e293b;
    text-transform: lowercase;
  }
 

  .aiCityAutoItem:hover {
    background: #eff6ff;
	 background: #2563eb;            /* blue highlight */
  color: #ffffff;                 /* white text */
  }

  .aiHint {
    font-size: 11px;
    color: #9ca3af;
    margin-top: 2px;
  }
  
 
  /* make dropdown text small letters */
  .aiSelect option {
    text-transform: lowercase;
  }
  
  .aiCityInput {
   background:#fff;
   cursor:text;
}


/* Hide School Type (Gender) block */
.aiFilterBlock[data-hide="gender"] {
    display: none !important;
}

/* smaller chips for result refiners */
.aiChip.aiChipSm {
  font-size: 11px;
  padding: 3px 9px;
}

/* result refine bar above cards */
.resultRefine {
  margin: 8px 0 12px 0;
}

.resultRefineLabel {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 6px;
}

/* city suggestion panel highlight (already similar, but a bit stronger) */
.aiCityAutoSuggestions {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 20;
  border-radius: 8px;
  border: 1px solid #d1d5db;
  margin-top: 2px;
  max-height: 220px;
  overflow-y: auto;
  box-shadow: 0 12px 25px rgba(15,23,42,0.22);
}

.aiCityAutoItem {
  padding: 7px 10px;
  font-size: 13px;
  cursor: pointer;
  text-transform: lowercase;
}


/* loading overlay while searching */
.aiLoadingOverlay {
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  background: rgba(15,23,42,0.32);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}
.aiLoadingBox {
  background: #ffffff;
  border-radius: 12px;
  padding: 14px 18px;
  box-shadow: 0 10px 25px rgba(15,23,42,0.20);
  font-family: Arial, Helvetica, sans-serif;
  display: flex;
  align-items: center;
  gap: 10px;
}
.aiSpinner {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 2px solid #e5e7eb;
  border-top-color: #2563eb;
  animation: aiSpin 0.8s linear infinite;
}
.aiLoadingText {
  font-size: 13px;
  font-weight: 500;
}
.sortLabel {
  margin-right: 4px;
}

.sortIcon {
  font-size: 11px;
  color: #6b7280;
}
.aiClearBtn {
  background: #e5e7eb;
  border: 1px solid #d1d5db;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  color: #374151;
}
.aiClearBtn:hover {
  background: #d1d5db;
}

/* red heart button css start*/

/* ---- HEART BUTTON IN HEADER ---- */
/* Header row: name + actions on right */
.schoolHeaderRow {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.schoolTitleBlock {
    flex: 1;
    min-width: 0; /* allow text to wrap nicely */
}

.schoolName {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 4px;
}

/* Actions on the right (View details + Send Enquiry) */
.schoolActions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Header heart button */
.aiFavBtnHeader {
    background: #ffffff;
    border: 1px solid #ffff;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    /*color: #ef4444;*/
	-webkit-text-stroke: 1px #ef4444;
    border-radius: 999px;
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin-right: 4px;  /* small gap before View details */
    transition: 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.aiFavBtnHeader:hover {
    transform: scale(1.08);
    background: #fee2e2;
}

/* Saved state – filled heart */
/* Top bar */
.favBar {
    display: flex;
    justify-content: flex-start;
    margin: 8px 0 6px;
}

.favCartBtn {
    background: #ef4444;
    color: #ffffff;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid #ef4444;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

/* Panel */
.favPanel {
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    padding: 10px 12px;
    margin-bottom: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    font-family: Arial, Helvetica, sans-serif;
}

.favPanelHeader {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #1e3a8a;
}
.favCloseBtn {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 14px;
}

.favList {
    max-height: 200px;
    overflow-y: auto;
}

/* Each saved school row */
.favItem {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid #dbeafe;
    font-size: 13px;
}

.favItem:last-child {
    border-bottom: none;
}

.favItemName {
    flex: 1;
    font-weight: 600;
    color: #111827;
}

.favItemActions button {
    background: #f9fafb;
    color: #111827;
    border: 1px solid #d1d5db;
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 11px;
    cursor: pointer;
    margin-left: 6px;
    transition: 0.15s ease;
}

.favItemActions button:hover {
    background: #e5e7eb;
}

.aiFavBtnHeader.isFav {
    background: #ef4444;   /* red fill */
    color: #ffffff;        /* white ♥ */
    border-color: #ef4444;
}

/* ---- HEART SAVE BUTTON IN ACTION ROW ---- */
.aiFavBtn {
    background: #ffffff;
    color: #ef4444;             /* heart outline color */
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    border: 1px solid #ef4444;  /* red border */
    cursor: pointer;
    display: inline-block;
    transition: 0.25s ease;
    margin-left: 6px;
}

.aiFavBtn:hover {
    background: #fee2e2;        /* light red background */
}

/* Filled (Saved) */
.aiFavBtn.isFav {
    background: #ef4444;        /* red */
    color: #ffffff;             /* white text */
    border-color: #ef4444;
}
.favCartBtn {
    background: #ef4444;
    color: #ffffff;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid #ef4444;
    cursor: pointer;
}
/* NEW Modern Saved Schools Panel */
.favPanel {
    background: linear-gradient(135deg, #f9fafb 0%, #e0f2fe 100%);
    border: 1px solid #dbeafe;
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(15,23,42,0.06);
}
@keyframes favPanelFade {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}
.favTopActions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 10px;
}

.favTopBtn {
    background: #ffffff;
    color: #1d4ed8;
    border-radius: 999px;
    border: 1px solid #bfdbfe;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s ease;
    box-shadow: 0 1px 2px rgba(15,23,42,0.05);
}

.favTopBtn:hover {
    background: #e0f2fe;
    border-color: #60a5fa;
}


/* Responsive tweaks */
@media (max-width: 768px) {
  .aiFavBtn { padding: 5px 12px; font-size: 12px; }
}

@media (max-width: 600px) {
  .aiFavBtn { padding: 4px 10px; font-size: 11px; }
}
/* Main decorated search box */
.aiCityStyledBox {
    position: relative;
    border: 1px solid #d1d5db;
    background: #ffffff;
    border-radius: 6px;
    padding-right: 36px;
}

/* Search icon */
.aiCitySearchIcon {
    position: absolute;
    right: 10px;
    top: 9px;
    font-size: 16px;
    color: #6b7280;
}

/* City input */
.aiCityInput {
    border: none !important;
    width: 100%;
    padding: 8px 12px;
    font-size: 14px;
    outline: none;
    background: transparent;
}

/* Suggestions box */
.aiCityAutoSuggestions {
    position: absolute;
    top: 38px;
    left: 0;
    width: 100%;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    max-height: 160px;
    overflow-y: auto;
    display: none;
    z-index: 2000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* Each suggestion */
.aiCityAutoItem {
    padding: 8px 12px;
    font-size: 14px;
    cursor: pointer;
    border-bottom: 1px solid #f3f4f6;
}

.aiCityAutoItem:hover {
    background: #f9fafb;
}

/* Area dropdown */
.aiAreaDropdown {
    margin-top: 6px;
}
/* 1) Lighter, smaller placeholder text */
.aiCityInput::placeholder {
  color: #9ca3af;        /* light grey */
  font-size: 12px;       /* smaller text */
}

/* For older browsers (optional) */
.aiCityInput::-webkit-input-placeholder { color:#9ca3af; font-size:12px; }
.aiCityInput:-ms-input-placeholder      { color:#9ca3af; font-size:12px; }

/* 2) Highlight the location box itself on focus */
.aiCityInput:focus {
  outline: none;
  border-color: #2563eb;                         /* blue border */
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25); /* soft glow */
}

/* 3) Suggestions box with shadow / highlight */
.aiCityAutoSuggestions {
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.18);
  border: 1px solid #e5e7eb;
}

/* 4) Suggestion items + hover state (text should NOT become white) */
.aiCityAutoItem {
  padding: 8px 12px;
  font-size: 14px;
  background: #ffffff;
  color: #111827;           /* dark text */
  cursor: pointer;
}

.aiCityAutoItem:hover {
  background: #eff6ff;      /* light blue highlight */
  color: #111827;           /* keep text dark */
}
.aiSendEnquiryBtn {
    background: #ffffff;
    color: #1e3a8a;               /* deep blue text */
    border: 1px solid #1e3a8a;    /* blue border */
    padding: 6px 16px;
    font-size: 12px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s ease;
}

/* Hover effect */
.aiSendEnquiryBtn:hover {
    background: #1e3a8a;          /* fill blue */
    color: #ffffff;               /* white text */
    box-shadow: 0 3px 10px rgba(30,58,138,0.25);
}

/* Click effect */
.aiSendEnquiryBtn:active {
    transform: scale(0.96);
}
.facility-chip {
    display: inline-block;
    padding: 3px 8px;
    margin: 2px 4px 2px 0;
    font-size: 11px;
    border-radius: 999px;
    background: #f1f5f9;   /* light pastel */
    color: #334155;
    border: 1px solid #e2e8f0;
    white-space: nowrap;
}

.facility-more-btn {
    font-size: 11px;
    margin-left: 6px;
    cursor: pointer;
    color: #2563eb;
}

/* Floating Scroll Toggle */
.aiScrollToggle {
    position: fixed;
    right: 18px;
    bottom: 120px;
    width: 44px;
    height: 44px;
    background: #2563eb;
    color: #fff;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.18);
    cursor: pointer;
    z-index: 9999;
    transition: background 0.2s ease, transform 0.2s ease;
}

.aiScrollToggle:hover {
    background: #1e3fa8;
    transform: translateY(-2px);
}

.aiScrollIcon {
    width: 22px;
    height: 22px;
    fill: #ffffff;
    transition: transform 0.25s ease;
}

/* When at bottom, rotate the chevron to point UP */
.aiScrollToggle.is-at-bottom .aiScrollIcon {
    transform: rotate(180deg);
}
/* ===== MOBILE PREFERENCES STICKY BAR ===== */
/* ===== MOBILE PREFERENCES STICKY BAR ===== */
.aiMobilePrefBar {
    display: none; /* default hidden (desktop) */
    background: #111827;
    color: #f9fafb;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
    z-index: 9998;
}

.aiMobilePrefText {
    display: flex;
    flex-direction: column;
    font-size: 12px;
}

.aiMobilePrefTitle {
    font-weight: 600;
    font-size: 13px;
}

.aiMobilePrefHint {
    font-size: 11px;
    opacity: 0.85;
}

.aiMobilePrefIconWrap {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
	padding: 0;
    box-sizing: border-box;
}

.aiMobilePrefIcon {
    width: 18px;
    height: 18px;
    fill: #ffffff;
    transition: transform 0.25s ease;
}

/* when filters are collapsed, rotate chevron up */
.aiMobilePrefBar.is-collapsed .aiMobilePrefIcon {
    transform: rotate(180deg);
}

/* ===== STICKY SORT / FILTER AREA ===== */
/* ===== STICKY SORT / FILTER AREA ===== */
/* Make results panel a reference for spacing tweaks */
.aiResultsPanel {
    position: relative;
}

/* ===== DESKTOP (>=769px) ===== */
@media (min-width: 769px) {

    .aiMobilePrefBar {
        display: none; /* hide bar completely on desktop */
    }

}

/* ===== MOBILE-ONLY (<=768px) ===== */
@media (max-width: 768px) {

    /* FIXED top bar on mobile */
    .aiMobilePrefBar {
        display: flex;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        margin: 0;
        border-radius: 0;
    }

    /* push content down so it’s not hidden behind bar */
    body {
        padding-top: 48px;
    }

    /* Collapse/expand the left filter card via max-height */
    .aiLeft {
        overflow: hidden;
        transition: max-height 0.3s ease,
                    padding-top 0.3s ease,
                    padding-bottom 0.3s ease,
                    margin-bottom 0.3s ease;
        max-height: 1200px; /* enough to show full form */
    }

    .aiLeft.aiFiltersCollapsed {
        max-height: 0;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
        border-width: 0;
    }

    /* SORT/CHIP BAR FIXED UNDER THE PREF BAR */
    .aiSortSticky {
        position: fixed;
        top: 48px;          /* same as body padding-top */
        left: 0;
        right: 0;
        z-index: 40;
        padding: 6px 12px;
        background: #f3f4f6;
        box-shadow: 0 2px 4px rgba(0,0,0,0.10);
    }

    /* give space so first result isn’t hidden behind fixed bar */
    .aiResultsPanel {
        margin-top: 96px;   /* adjust 80–110 if needs fine-tuning */
    }
}
.aiGoogleAdBox {
    margin: 20px 0;
    padding: 10px 0;
    border-radius: 8px;
    background: #fafafa;
}

@media(max-width: 768px){
    .aiGoogleAdBox {
        margin: 16px 0;
    }
}
