/* ============================================================
   tutor-list-v2.css
   Scoped styles for the redesigned /tutors discovery page.
   All rules live under .tl2 so they don't touch other pages.
   ============================================================ */

.tl2 {
  --tl2-primary: #4635B1;
  --tl2-primary-hover: #372a8f;
  --tl2-primary-soft: #EEEBFA;
  --tl2-ink: #101010;
  --tl2-ink-2: #2E2A44;
  --tl2-muted: #6B6B7B;
  --tl2-surface: #FFFFFF;
  --tl2-surface-alt: #F7F5FD;
  --tl2-border: #E8E6F1;
  --tl2-star: #F5B323;
  --tl2-verified: #21A400;

  --tl2-radius-sm: 8px;
  --tl2-radius-md: 12px;
  --tl2-radius-lg: 20px;
  --tl2-shadow-card: 0 4px 24px rgba(16, 16, 16, 0.06);
  --tl2-shadow-hover: 0 16px 40px rgba(70, 53, 177, 0.14);

  font-family: 'Gilroy', -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--tl2-ink);
  line-height: 1.5;
}

.tl2 * { box-sizing: border-box; }
.tl2 img { max-width: 100%; display: block; }
.tl2 a { color: inherit; text-decoration: none; }
.tl2 h1, .tl2 h2, .tl2 h3, .tl2 h4, .tl2 p { margin: 0; }

.tl2-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* -----------------------------------------------------------
   HERO STRIP  (compact, unlike the home hero)
   ----------------------------------------------------------- */
.tl2-hero {
  padding: 48px 0 32px;
  background: linear-gradient(180deg, var(--tl2-surface-alt) 0%, #fff 100%);
  text-align: center;
}
.tl2-hero h1 {
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--tl2-ink);
  margin-bottom: 12px;
}
.tl2-hero p {
  font-size: 17px;
  color: var(--tl2-muted);
  max-width: 620px;
  margin: 0 auto;
}

/* -----------------------------------------------------------
   FILTER BAR
   ----------------------------------------------------------- */
.tl2-filters {
  background: #fff;
  border-bottom: 1px solid var(--tl2-border);
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: 5;
}
.tl2-filters__inner {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.tl2-search {
  flex: 1 1 260px;
  min-width: 220px;
  position: relative;
}
.tl2-search input {
  width: 100%;
  padding: 12px 16px 12px 42px;
  border: 1.5px solid var(--tl2-border);
  border-radius: var(--tl2-radius-md);
  font-family: inherit;
  font-size: 15px;
  color: var(--tl2-ink);
  background: #fff;
  transition: border-color .15s ease;
}
.tl2-search input:focus {
  outline: none;
  border-color: var(--tl2-primary);
}
.tl2-search__icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--tl2-muted);
  pointer-events: none;
}

/* Subject chip group */
.tl2-chips { display: inline-flex; gap: 6px; }
.tl2-chip-btn {
  background: #fff;
  border: 1.5px solid var(--tl2-border);
  border-radius: 999px;
  padding: 8px 16px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--tl2-muted);
  cursor: pointer;
  transition: all .15s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tl2-chip-btn:hover { color: var(--tl2-ink); border-color: var(--tl2-ink-2); }
.tl2-chip-btn.is-active {
  background: var(--tl2-primary);
  border-color: var(--tl2-primary);
  color: #fff;
}

/* Dropdown filters — native <select> styled */
.tl2-select {
  position: relative;
  display: inline-block;
}
.tl2-select select {
  appearance: none;
  -webkit-appearance: none;
  padding: 10px 36px 10px 14px;
  border: 1.5px solid var(--tl2-border);
  border-radius: var(--tl2-radius-md);
  background: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--tl2-ink);
  cursor: pointer;
  transition: border-color .15s ease;
}
.tl2-select select:focus { outline: none; border-color: var(--tl2-primary); }
.tl2-select::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--tl2-muted);
  border-bottom: 1.5px solid var(--tl2-muted);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

/* -----------------------------------------------------------
   RESULTS HEADER
   ----------------------------------------------------------- */
.tl2-results-head {
  padding: 24px 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.tl2-results-head p {
  font-size: 15px;
  color: var(--tl2-muted);
}
.tl2-results-head strong {
  color: var(--tl2-ink);
  font-weight: 700;
}

/* -----------------------------------------------------------
   GRID
   ----------------------------------------------------------- */
.tl2-body { padding-bottom: 64px; }
.tl2-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* -----------------------------------------------------------
   CARD
   ----------------------------------------------------------- */
.tl2-card {
  display: block;
  background: #fff;
  border: 1px solid var(--tl2-border);
  border-radius: var(--tl2-radius-lg);
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  position: relative;
}
.tl2-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--tl2-shadow-hover);
  border-color: transparent;
}
.tl2-card__media {
  aspect-ratio: 4 / 5;
  background: var(--tl2-primary-soft);
  position: relative;
  overflow: hidden;
}
.tl2-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}
.tl2-card:hover .tl2-card__media img { transform: scale(1.03); }

.tl2-card__verified {
  position: absolute;
  top: 14px;
  right: 14px;
  background: var(--tl2-verified);
  color: #fff;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 4px 10px rgba(33, 164, 0, 0.3);
  border: 2px solid #fff;
}
.tl2-card__rating-overlay {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(16, 16, 16, 0.72);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  padding: 6px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  backdrop-filter: blur(4px);
}
.tl2-card__rating-overlay em {
  color: rgba(255, 255, 255, 0.75);
  font-style: normal;
  font-weight: 500;
  font-size: 12px;
}

.tl2-card__body { padding: 18px 20px 20px; }

.tl2-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.tl2-card__name {
  font-size: 18px;
  font-weight: 700;
  color: var(--tl2-ink);
  line-height: 1.2;
}

.tl2-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}
.tl2-chip {
  background: var(--tl2-primary-soft);
  color: var(--tl2-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.tl2-card__meta {
  font-size: 13px;
  color: var(--tl2-muted);
  margin-bottom: 12px;
}

/* Free demo indicator — shown on every tutor card, above the price/CTA row */
.tl2-card__free-demo {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--tl2-success-soft);
  color: var(--tl2-success);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
  align-self: flex-start;
  letter-spacing: 0.01em;
}

.tl2-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--tl2-border);
}
.tl2-card__price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  flex-wrap: wrap;
}
.tl2-card__price span:first-child {
  font-size: 12px;
  color: var(--tl2-muted);
  font-weight: 500;
}
.tl2-card__price strong {
  font-size: 20px;
  font-weight: 700;
  color: var(--tl2-ink);
  line-height: 1;
}
.tl2-card__price em {
  font-size: 12px;
  color: var(--tl2-muted);
  font-style: normal;
  font-weight: 500;
}
.tl2-card__cta {
  font-size: 13px;
  font-weight: 700;
  color: var(--tl2-primary);
  padding: 8px 12px;
  border-radius: var(--tl2-radius-md);
  background: var(--tl2-primary-soft);
  transition: background .15s ease;
  white-space: nowrap;
}
.tl2-card:hover .tl2-card__cta { background: var(--tl2-primary); color: #fff; }

/* -----------------------------------------------------------
   EMPTY STATE
   ----------------------------------------------------------- */
.tl2-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
  background: var(--tl2-surface-alt);
  border-radius: var(--tl2-radius-lg);
  color: var(--tl2-muted);
}
.tl2-empty h3 {
  color: var(--tl2-ink);
  font-size: 20px;
  margin-bottom: 8px;
}

/* -----------------------------------------------------------
   COMING SOON STRIP — sits between tutor grid and pagination
   ----------------------------------------------------------- */
.tl2-coming-strip {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 22px;
  margin-top: 32px;
  background: var(--tl2-surface-alt);
  border: 1px dashed rgba(70, 53, 177, 0.28);
  border-radius: var(--tl2-radius-lg);
}
.tl2-coming-strip__icon {
  flex-shrink: 0;
  font-size: 22px;
  line-height: 1;
  padding-top: 2px;
  filter: grayscale(0.1);
}
.tl2-coming-strip__body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--tl2-muted);
  font-size: 14px;
  line-height: 1.5;
}
.tl2-coming-strip__body strong {
  color: var(--tl2-ink);
  font-weight: 700;
  font-size: 15px;
}
.tl2-coming-strip__body em {
  font-style: normal;
  color: var(--tl2-primary);
  font-weight: 600;
}

/* -----------------------------------------------------------
   PAGINATION
   ----------------------------------------------------------- */
.tl2-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 40px 0 0;
}
.tl2-pagination a,
.tl2-pagination .tl2-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 14px;
  border-radius: var(--tl2-radius-md);
  border: 1px solid var(--tl2-border);
  color: var(--tl2-ink);
  font-weight: 600;
  font-size: 14px;
  background: #fff;
  cursor: pointer;
  transition: all .15s ease;
}
.tl2-pagination a:hover { border-color: var(--tl2-primary); color: var(--tl2-primary); }
.tl2-pagination a.current,
.tl2-pagination .tl2-page-btn.current {
  background: var(--tl2-primary);
  border-color: var(--tl2-primary);
  color: #fff;
}
.tl2-pagination ul {
  display: flex;
  gap: 6px;
  list-style: none;
  padding: 0;
  margin: 0;
}

/* -----------------------------------------------------------
   BOTTOM CTA BANNER
   ----------------------------------------------------------- */
.tl2-final-cta {
  background: linear-gradient(135deg, var(--tl2-primary) 0%, #6b5cd6 100%);
  color: #fff;
  padding: 64px 0;
  text-align: center;
}
.tl2-final-cta h2 {
  color: #fff;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
.tl2-final-cta p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 17px;
  margin-bottom: 24px;
}
.tl2-final-cta .tl2-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--tl2-primary);
  padding: 14px 28px;
  border-radius: var(--tl2-radius-md);
  font-weight: 700;
  font-size: 16px;
  transition: background .15s ease;
}
.tl2-final-cta .tl2-btn:hover { background: #f4f2fd; }

/* -----------------------------------------------------------
   RESPONSIVE
   ----------------------------------------------------------- */
@media (max-width: 1024px) {
  .tl2-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .tl2-hero { padding: 32px 0 24px; }
  .tl2-filters { padding: 14px 0; position: static; }
  .tl2-filters__inner { flex-direction: column; align-items: stretch; }
  .tl2-search { flex: 1 1 auto; }
  .tl2-chips { justify-content: flex-start; overflow-x: auto; }
  .tl2-grid { grid-template-columns: 1fr; }
  .tl2-final-cta { padding: 48px 0; }
}
