/* =========================================================================
   Find Instructors — base styles.
   Colors/spacing that Elementor controls override live here as defaults so
   AJAX-injected markup always looks correct.
   ====================================================================== */

.fi-wrap { position: relative; }

/* ---- Search bar ---- */
.fi-searchbar {
	display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
	background: #fff; border: 1px solid #E5E7EB; border-radius: 14px;
	padding: 8px 8px 8px 16px; margin-bottom: 22px;
}
.fi-search-field { display: flex; align-items: center; gap: 10px; flex: 1 1 220px; min-width: 160px; }
.fi-ic-search { width: 20px; height: 20px; color: #6B7280; flex-shrink: 0; }
.fi-search-input {
	flex: 1 1 auto; border: 0; outline: 0; background: transparent;
	font-size: 16px; color: #111827; padding: 8px 0; min-width: 0; font-family: inherit;
}
.fi-search-input::placeholder { color: #9CA3AF; }

/* Dropdowns */
.fi-dd { position: relative; border-left: 1px solid #E5E7EB; padding-left: 8px; }
.fi-dd-toggle {
	display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
	background: transparent; border: 0; padding: 10px 12px; border-radius: 8px;
	font-size: 15px; color: #374151; font-family: inherit; white-space: nowrap;
}
.fi-dd-toggle:hover { background: #F9FAFB; }
.fi-ic-layers { width: 18px; height: 18px; color: #EC4899; flex-shrink: 0; }
.fi-ic-chevron { width: 16px; height: 16px; transition: transform .2s ease; flex-shrink: 0; }
.fi-dd.is-open .fi-ic-chevron { transform: rotate(180deg); }
.fi-dd-label { font-weight: 500; }

.fi-dd-panel {
	position: absolute; top: calc(100% + 8px); left: 0; z-index: 40; display: none;
	min-width: 220px; max-height: 300px; overflow-y: auto;
	background: #fff; border: 1px solid #E5E7EB; border-radius: 12px;
	box-shadow: 0 12px 30px rgba(17,24,39,.12); padding: 6px;
}
.fi-dd.is-open .fi-dd-panel { display: block; }
.fi-dd-opt {
	display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px;
	font-size: 14px; color: #374151; cursor: pointer;
}
.fi-dd-opt:hover { background: #F9FAFB; }
.fi-dd-opt input { width: 16px; height: 16px; accent-color: #EC4899; cursor: pointer; flex-shrink: 0; }

/* Search button */
.fi-search-btn {
	flex-shrink: 0; margin-left: auto; cursor: pointer; border: 0;
	background: #DB2777; color: #fff; font-size: 15px; font-weight: 600;
	padding: 12px 26px; border-radius: 10px; transition: background .2s ease; font-family: inherit;
}
.fi-search-btn:hover { background: #BE185D; }

/* ---- Results header ---- */
.fi-resulthead { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.fi-rh-left { font-size: 20px; font-weight: 700; color: #1F2937; }
.fi-rh-right { font-size: 14px; color: #6B7280; }
.fi-rh-accent { color: #DB2777; }

/* ---- List ---- */
.fi-list { display: flex; flex-direction: column; gap: 20px; }

/* ---- Card (reference design) ---- */
.fi-wrap {
	--fi-accent: #C11574;
	--fi-accent-dark: #A80F63;
	--fi-ring: #FD3E9B;
	--fi-teal: #0E9384;
	--fi-navy: #1C1259;
	--fi-text: #3F3C63;
}

.fi-card {
	display: flex; gap: 24px; align-items: flex-start;
	background: #fff; border-radius: 16px; padding: 28px 32px;
	box-shadow: 0 2px 10px rgba(28,18,89,.06);
	transition: transform .2s ease, box-shadow .2s ease;
}
.fi-card:hover { box-shadow: 0 10px 30px rgba(28,18,89,.12); }

/* Left: circular avatar + rating */
.fi-card-media { flex: 0 0 130px; max-width: 130px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.fi-avatar-wrap { position: relative; display: inline-flex; }
.fi-avatar-ring { display: inline-flex; padding: 4px; border-radius: 50%; border: 3px solid var(--fi-ring); background: #fff; }
.fi-avatar { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; display: block; }
.fi-avatar-fallback { display: flex; align-items: center; justify-content: center; background: #FCE7F1; color: var(--fi-accent); font-size: 36px; font-weight: 700; }
.fi-avatar-check { position: absolute; right: 2px; bottom: 6px; width: 24px; height: 24px; color: #16A34A; background: #fff; border-radius: 50%; box-shadow: 0 1px 4px rgba(0,0,0,.15); }
.fi-avatar-check svg { width: 100%; height: 100%; display: block; }

.fi-rating-under { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.fi-rating-under .fi-reviews { font-size: 13px; color: var(--fi-text); }

/* Middle: content */
.fi-card-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 9px; padding-top: 6px; }
.fi-name-wrap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fi-card-name { margin: 0; font-size: 19px; font-weight: 800; color: var(--fi-navy); line-height: 1.2; }
.fi-verified-wrap { display: inline-flex; align-items: center; gap: 4px; color: var(--fi-teal); font-size: 14px; font-weight: 600; }
.fi-verified { width: 17px; height: 17px; color: var(--fi-teal); flex-shrink: 0; }
.fi-badge { flex-shrink: 0; background: #EEF2FF; color: #3730A3; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 20px; white-space: nowrap; }

.fi-edu { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 15px; color: var(--fi-text); }
.fi-edu-qual { font-weight: 700; color: var(--fi-navy); }
.fi-dot { color: #9CA3AF; }

.fi-online {
	display: inline-flex; align-items: center; padding: 3px 14px; border-radius: 999px;
	background: #F0FDF9; border: 1px solid #99F6E0; color: var(--fi-teal);
	font-size: 13px; font-weight: 600;
}

.fi-meta-row { display: inline-flex; align-items: center; gap: 5px; font-size: 14px; color: var(--fi-text); }
.fi-meta-row svg { width: 15px; height: 15px; color: #9CA3AF; flex-shrink: 0; }
.fi-save { background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; color: #6B7280; font-size: 14px; font-family: inherit; }
.fi-ic-heart { width: 16px; height: 16px; }
.fi-save.is-saved { color: var(--fi-accent); }
.fi-save.is-saved .fi-ic-heart { fill: var(--fi-accent); }

/* Description (italic per reference) */
.fi-card-desc {
	margin: 0; font-size: 15px; line-height: 1.7; font-style: italic; color: var(--fi-navy);
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* Subjects: book icon + comma list */
.fi-subjects-line { display: flex; align-items: center; gap: 8px; color: var(--fi-text); font-size: 14px; }
.fi-subjects-line svg { width: 18px; height: 18px; color: var(--fi-navy); flex-shrink: 0; }
.fi-subject-more { color: var(--fi-accent); font-weight: 600; cursor: help; }

/* Right: action buttons */
.fi-card-actions { flex: 0 0 auto; display: flex; flex-direction: column; gap: 12px; align-self: center; min-width: 170px; }
.fi-btn {
	display: inline-flex; align-items: center; justify-content: center;
	text-decoration: none; text-align: center; cursor: pointer;
	border-radius: 999px; padding: 12px 26px; font-size: 15px; font-weight: 700;
	transition: all .15s ease;
}
.fi-btn-contact { background: var(--fi-accent); color: #fff; border: 2px solid var(--fi-accent); }
.fi-btn-contact:hover { background: var(--fi-accent-dark); border-color: var(--fi-accent-dark); color: #fff; }
.fi-btn-view { background: #fff; color: var(--fi-accent); border: 2px solid var(--fi-accent); }
.fi-btn-view:hover { background: var(--fi-accent); color: #fff; }

/* ---- Rating stars ---- */
.fi-rating { display: inline-flex; align-items: center; gap: 5px; }
.fi-rating-text { font-size: 14px; font-weight: 700; color: var(--fi-navy); }
.fi-stars { position: relative; display: inline-flex; width: 90px; height: 16px; flex-shrink: 0; }
.fi-stars-base, .fi-stars-fill { position: absolute; top: 0; left: 0; display: flex; overflow: hidden; white-space: nowrap; height: 16px; }
.fi-stars-base { color: #E5E7EB; width: 100%; }
.fi-stars-fill { color: #F59E0B; width: 0; }
.fi-stars svg { width: 18px; height: 16px; flex-shrink: 0; }
.fi-reviews { font-size: 13px; color: #6B7280; }

/* Divider (optional) */
.fi-divider { height: 1px; background: #EEF0F4; margin: 2px 0; width: 100%; }

/* ---- Optional extras (toggle on in the widget) ---- */
/* Price */
.fi-price { flex-shrink: 0; }
.fi-price-label { display: block; font-size: 12px; color: #6B7280; line-height: 1.2; }
.fi-price-value { font-size: 20px; font-weight: 800; color: var(--fi-accent); }
.fi-price-suffix { font-size: 14px; font-weight: 400; color: #6B7280; }

/* Availability */
.fi-availability { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.fi-av-label { font-size: 14px; font-weight: 600; color: var(--fi-navy); }
.fi-days { display: flex; gap: 6px; flex-wrap: wrap; }
.fi-day { font-size: 11px; font-weight: 600; color: #9CA3AF; border: 1px solid #E5E7EB; border-radius: 8px; padding: 5px 8px; letter-spacing: .02em; }
.fi-day.is-on { color: var(--fi-accent); border-color: #F9A8D4; background: #FDF2F8; }

/* Teaching modes */
.fi-modes-label { display: block; font-size: 13px; font-weight: 600; color: var(--fi-accent); margin-bottom: 6px; }
.fi-mode-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.fi-chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #E5E7EB; border-radius: 10px; padding: 7px 12px; font-size: 13px; color: #374151; }
.fi-chip svg { width: 16px; height: 16px; }
.fi-chip:nth-child(1) svg { color: #F97316; }
.fi-chip:nth-child(2) svg { color: #14B8A6; }

/* Stats */
.fi-stats { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 2px; }
.fi-stat { flex: 1 1 auto; min-width: 90px; background: #F9FAFB; border-radius: 12px; padding: 10px 14px; display: flex; flex-direction: column; gap: 2px; }
.fi-stat-value { font-size: 16px; font-weight: 700; color: var(--fi-navy); line-height: 1.1; }
.fi-stat-label { font-size: 12px; color: #6B7280; }

/* Specialization row */
.fi-spec { font-size: 14px; }

/* Trial */
.fi-trial { background: #DCFCE7; color: #15803D; border: 1px solid #BBF7D0; font-size: 12px; font-weight: 500; padding: 4px 12px; border-radius: 999px; white-space: nowrap; }

/* Level badges (categories) */
.fi-levels { display: flex; gap: 6px; flex-wrap: wrap; }
.fi-level { background: #EEF2FF; color: #4338CA; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }

/* ---- Empty ---- */
.fi-empty { padding: 40px 20px; text-align: center; color: #6B7280; border: 1px dashed #E5E7EB; border-radius: 16px; }

/* ---- Pagination ---- */
.fi-pagination { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 32px; flex-wrap: wrap; }
.fi-page {
	display: inline-flex; align-items: center; justify-content: center;
	width: 38px; height: 38px; border: 1px solid #E5E7EB; background: #fff; color: #6B7280;
	border-radius: 999px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all .2s ease;
}
.fi-page:hover:not(.is-active):not([disabled]) { border-color: #9CA3AF; color: #111827; }
.fi-page.is-active { background: #111827; color: #fff; border-color: #111827; }
.fi-page[disabled] { opacity: .3; cursor: not-allowed; }
.fi-page-dots { color: #9CA3AF; padding: 0 4px; }

.fi-loadmore-wrap { display: flex; justify-content: center; margin-top: 28px; }
.fi-loadmore {
	border: 1px solid #E5E7EB; background: #fff; color: #6B7280; cursor: pointer;
	border-radius: 999px; padding: 12px 28px; font-size: 14px; font-weight: 600; transition: all .2s ease;
}
.fi-loadmore:hover { border-color: #9CA3AF; color: #111827; }

/* ---- Loading state ---- */
.fi-results { transition: opacity .2s ease; }
.fi-results.is-loading { opacity: .45; pointer-events: none; }

/* ---- Responsive ---- */
@media (max-width: 767px) {
	.fi-card { flex-direction: column; align-items: center; text-align: center; }
	.fi-card-media { flex-basis: auto; max-width: 100%; }
	.fi-card-body { align-items: center; }
	.fi-edu, .fi-name-wrap, .fi-subjects-line { justify-content: center; }
	.fi-card-actions { width: 100%; min-width: 0; align-self: stretch; }
	.fi-btn { width: 100%; }

	.fi-searchbar { flex-direction: column; align-items: stretch; padding: 12px; }
	.fi-search-field { border-bottom: 1px solid #E5E7EB; padding-bottom: 10px; }
	.fi-dd { border-left: 0; padding-left: 0; }
	.fi-dd-toggle { width: 100%; justify-content: flex-start; }
	.fi-dd-panel { position: static; box-shadow: none; border: 0; padding-left: 26px; }
	.fi-search-btn { margin-left: 0; width: 100%; }
}
