/**
 * User profile page – image style (teleteach theme)
 * Light gradient header, rounded cards, blue active tab, summary cards, course grid
 */

/* ---- Variables ---- */
.userpage-teleteach {
  --user-header-bg-start: #e8f4fc;
  --user-header-bg-end: #ffffff;
  --user-dot-fill: rgba(46, 204, 113, 0.25);
  --user-tab-active: #3498db;
  --user-tab-inactive: #5a6c7d;
  --user-card-bg: #ffffff;
  --user-card-shadow: 0 1px 8px rgba(0, 0, 0, 0.08);
  --user-price-free: #e67e22;
  --user-signature-border: rgba(46, 204, 113, 0.5);
  --user-signature-text: rgba(46, 204, 113, 0.8);
}

/* ---- Header ---- */
body.userpage.userpage-teleteach .user-profile-header-teleteach {
  background: linear-gradient(135deg, var(--user-header-bg-start) 0%, var(--user-header-bg-end) 55%);
  border-radius: 16px;
  padding: 28px 32px;
  margin-bottom: 0;
  position: relative;
  overflow: hidden;
}

.user-profile-header-inner {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 24px;
  position: relative;
  z-index: 1;
}

.user-profile-header-left {
  display: flex;
  align-items: center;
  gap: 24px;
  flex: 1;
  min-width: 0;
}

.user-profile-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.user-profile-avatar-img {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.user-profile-avatar-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e74c3c;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.user-profile-dots-decor {
  position: absolute;
  left: 140px;
  top: 50%;
  transform: translateY(-50%);
  width: 80px;
  height: 80px;
  pointer-events: none;
}

.user-profile-dots-decor::before,
.user-profile-dots-decor::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: var(--user-dot-fill);
}

.user-profile-dots-decor::before {
  width: 24px;
  height: 24px;
  left: 0;
  top: 0;
}

.user-profile-dots-decor::after {
  width: 16px;
  height: 16px;
  left: 32px;
  top: 20px;
}

.user-profile-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
}

.user-profile-name {
  font-size: 22px;
  font-weight: 700;
  color: #2c3e50;
  margin: 0;
  line-height: 1.3;
}

.user-profile-username {
  font-size: 14px;
  color: #5a6c7d;
  margin: 0;
}

.user-profile-points {
  font-size: 16px;
  color: #2c3e50;
  margin: 0;
}

.user-profile-social {
  font-size: 14px;
  color: #5a6c7d;
  margin-top: 4px;
}

.user-profile-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.user-profile-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: opacity 0.2s;
}

.user-profile-btn:hover {
  opacity: 0.9;
}

.user-profile-btn-follow,
.user-profile-btn-unfollow {
  background: var(--user-tab-active);
  color: #fff;
  border-color: var(--user-tab-active);
}

.user-profile-btn-message {
  background: #e8f4fc;
  color: var(--user-tab-active);
  border-color: #b8d9f0;
}

.user-profile-signature-wrap {
  flex-shrink: 0;
  align-self: stretch;
  display: flex;
  align-items: stretch;
}

.user-profile-signature-box {
  min-width: 200px;
  max-width: 280px;
  padding: 16px 20px;
  border: 2px dashed var(--user-signature-border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.6);
}

.user-profile-signature-text {
  font-size: 14px;
  color: #2c3e50;
}

.user-profile-signature-empty {
  color: var(--user-signature-text);
}

.user-profile-signature-wave {
  width: 100%;
  max-width: 140px;
  color: var(--user-signature-text);
  opacity: 0.8;
}

.user-profile-signature-wave svg {
  width: 100%;
  height: auto;
  display: block;
}

/* ---- Tabs (image style: container with grey bg, active pill + blue bottom line, separators) ---- */
body.userpage.userpage-teleteach .userpage-nav-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: flex-start;
  gap: 0;
  padding: 6px 8px;
  margin-bottom: 20px;
  background-color: #f8f9fa;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

body.userpage.userpage-teleteach .userpage-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  font-size: 15px;
  color: #5f6368;
  text-decoration: none;
  position: relative;
  font-weight: 500;
  border-radius: 6px;
  transition: background-color 0.2s, color 0.2s;
  border-right: 1px solid #e0e0e0;
}

body.userpage.userpage-teleteach .userpage-tab:last-child {
  border-right: none;
}

body.userpage.userpage-teleteach .userpage-tab:hover {
  color: #1976d2;
}

body.userpage.userpage-teleteach .userpage-tab.active {
  background-color: #e0f0ff;
  color: #1e90ff;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 6px;
  margin-bottom: -1px;
  border-bottom: 2px solid #1e90ff;
  z-index: 1;
}

body.userpage.userpage-teleteach .userpage-tab.active::after {
  content: none;
}

/* ---- Summary cards ---- */
body.userpage.userpage-teleteach .user-profile-summary-cards-teleteach {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

body.userpage.userpage-teleteach .summary-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  background: var(--user-card-bg);
  border-radius: 14px;
  box-shadow: var(--user-card-shadow);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s;
}

body.userpage.userpage-teleteach .summary-card:hover {
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
}

.summary-card-icon {
  color: var(--user-tab-active);
  font-size: 22px;
}

.summary-card-value {
  font-size: 20px;
  font-weight: 700;
  color: #2c3e50;
}

.summary-card-label {
  font-size: 14px;
  color: #5a6c7d;
  margin-right: auto;
}

.summary-card-chevron {
  color: #bdc3c7;
  font-size: 16px;
}

/* ---- Main content & course list ---- */
body.userpage.userpage-teleteach .userpage-main-content {
  margin-top: 0;
}

/* Following/Follower sub-pills: do NOT pull up into summary cards (override global .nav.nav-pills.mbl margin-top: -56px) */
body.userpage.userpage-teleteach .userpage-friend-pills,
body.userpage.userpage-teleteach .userpage-main-content .nav.nav-pills.mbl {
  margin-top: 0 !important;
  margin-bottom: 20px;
}

body.userpage.userpage-teleteach .userpage-empty {
  text-align: center;
  padding: 48px 20px;
  color: #7f8c8d;
  font-size: 15px;
}

body.userpage.userpage-teleteach .userpage-paginator {
  margin-top: 24px;
  margin-bottom: 24px;
}

/* Course grid – rounded cards, image, title, metas, orange Free */
body.userpage.userpage-teleteach .userpage-course-list-wrap .course-list {
  margin: 0;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-list .row {
  margin-left: -10px;
  margin-right: -10px;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-list .col-lg-3,
body.userpage.userpage-teleteach .userpage-course-list-wrap .course-list .col-md-4,
body.userpage.userpage-teleteach .userpage-course-list-wrap .course-list .col-xs-6 {
  padding-left: 10px;
  padding-right: 10px;
  margin-bottom: 20px;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-item {
  background: var(--user-card-bg);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--user-card-shadow);
  transition: box-shadow 0.2s;
  height: 100%;
  display: flex;
  flex-direction: column;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-item:hover {
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-img {
  border-radius: 14px 14px 0 0;
  overflow: hidden;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-img a {
  display: block;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-img img {
  width: 100%;
  height: auto;
  display: block;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-info {
  padding: 14px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-info .title {
  margin-bottom: 8px;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-info .title a {
  font-size: 15px;
  font-weight: 600;
  color: #2c3e50;
  text-decoration: none;
  line-height: 1.4;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-info .title a:hover {
  color: var(--user-tab-active);
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .metas {
  font-size: 13px;
  color: #7f8c8d;
  margin-top: auto;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .metas .num,
body.userpage.userpage-teleteach .userpage-course-list-wrap .metas .comment {
  margin-right: 12px;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .metas i {
  margin-right: 4px;
}

body.userpage.userpage-teleteach .userpage-course-list-wrap .course-price-widget .color-success,
body.userpage.userpage-teleteach .userpage-course-list-wrap .course-price-widget .price .color-success {
  color: var(--user-price-free) !important;
  font-weight: 600;
}

/* Content container for user page */
body.userpage.userpage-teleteach #content-container {
  padding-left: 16px;
  padding-right: 16px;
}

/* Responsive */
@media (max-width: 991px) {
  .user-profile-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .user-profile-signature-wrap {
    width: 100%;
  }

  .user-profile-signature-box {
    max-width: none;
    min-width: 0;
  }
}

@media (max-width: 767px) {
  body.userpage.userpage-teleteach .user-profile-header-teleteach {
    padding: 20px 16px;
  }

  .user-profile-header-left {
    flex-wrap: wrap;
  }

  .user-profile-dots-decor {
    display: none;
  }

  .user-profile-avatar-img {
    width: 72px;
    height: 72px;
  }

  .user-profile-name {
    font-size: 18px;
  }

  body.userpage.userpage-teleteach .user-profile-summary-cards-teleteach {
    grid-template-columns: 1fr;
  }

  body.userpage.userpage-teleteach .userpage-nav-tabs {
    padding: 6px;
  }

  body.userpage.userpage-teleteach .userpage-tab {
    font-size: 13px;
    padding: 8px 12px;
  }
}
