/* =============================================
   JetToSkills — Application Stylesheet v2
   Confident & Approachable — Coral + Warm Charcoal
   ============================================= */

/* === Custom CSS variables (used by legacy component classes below) === */
:root {
  /* Primary — Coral */
  --color-primary:      #f97316;
  --color-primary-dk:   #c2410c;
  --color-primary-lt:   #fff7ed;
  --color-primary-tint: #fff4e6;

  /* CTA — same as primary */
  --color-cta:    #f97316;
  --color-cta-dk: #c2410c;
  --color-cta-lt: #fff7ed;

  /* Semantic */
  --color-success: #16a34a;
  --color-danger:  #dc2626;
  --color-warning: #d97706;
  --color-info:    #0891b2;

  /* Neutrals */
  --color-muted:   #78716c;
  --color-border:  #e8e2db;
  --color-bg:      #fdf8f4;
  --color-surface: #ffffff;
  --color-text:    #1c1917;

  /* Typography */
  --font-sans:    "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans TC", "PingFang TC", sans-serif;
  --font-display: "DM Serif Display", Georgia, serif;

  /* Shape */
  --radius-sm: 6px;
  --radius:    10px;
  --radius-lg: 14px;
  --radius-xl: 20px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.04);
  --shadow:    0 4px 12px rgba(0,0,0,.09), 0 2px 4px rgba(0,0,0,.04);
  --shadow-md: 0 8px 24px rgba(0,0,0,.10), 0 4px 8px rgba(0,0,0,.05);
  --shadow-lg: 0 16px 40px rgba(0,0,0,.13), 0 8px 16px rgba(0,0,0,.06);

  /* Layout */
  --sidebar-width:  240px;
  --content-width: 1040px;
}


/* === Flash === */
.flash {
  padding: .8rem 1.25rem;
  border-radius: var(--radius);
  margin: 1rem 1.5rem;
  font-weight: 500;
  font-size: .9rem;
}
.flash--notice { background: #d1fae5; color: #065f46; border: 1px solid #6ee7b7; }
.flash--alert  { background: #fee2e2; color: #7f1d1d; border: 1px solid #fca5a5; }

/* === Top Navigation === */
.topnav {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}
.topnav__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: .85rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.topnav__brand {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--color-primary);
  text-decoration: none;
  flex-shrink: 0;
  letter-spacing: -.02em;
}
.topnav__brand:hover { text-decoration: none; color: var(--color-primary-dk); }

.topnav__links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-left: auto;
  flex-wrap: wrap;
  font-size: .875rem;
}
.topnav__links a { color: var(--color-muted); font-weight: 500; }
.topnav__links a:hover { color: var(--color-text); text-decoration: none; }
.topnav__user { color: var(--color-text) !important; font-weight: 600 !important; }

.topnav__lang { display: flex; align-items: center; gap: 2px; margin-left: .5rem; }
.topnav__lang-sep { color: var(--color-border); font-size: .8rem; }
.topnav__lang-btn {
  background: none;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: .2rem .5rem;
  font-size: .78rem;
  font-weight: 600;
  color: var(--color-muted);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: all .15s;
}
.topnav__lang-btn:hover { border-color: var(--color-border); color: var(--color-text); }
.topnav__lang-btn--active {
  background: var(--color-primary-lt);
  color: var(--color-primary);
  border-color: var(--color-primary-lt);
}

/* === Layout: Public / Learner === */
.learner-layout main {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

/* === Layout: Dashboard (Tutor sidebar) === */
.dashboard-layout { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-width);
  background: var(--color-text);
  color: #d1d5db;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: fixed;
  top: 0; left: 0; bottom: 0;
}
.sidebar__brand { padding: 1.25rem 1rem; border-bottom: 1px solid #374151; }
.sidebar__logo  { color: #fff; font-size: 1.1rem; font-weight: 700; display: block; }
.sidebar__logo:hover { text-decoration: none; }
.sidebar__nav { list-style: none; padding: .5rem 0; flex: 1; overflow-y: auto; }
.sidebar__nav li { position: relative; }
.sidebar__nav li a { display: block; padding: .6rem 1rem; color: #d1d5db; font-size: .9rem; }
.sidebar__nav li a:hover { color: #fff; background: #374151; text-decoration: none; }
.sidebar__nav li.active a { color: #fff; background: var(--color-primary); }
.sidebar__nav li .badge { position: absolute; right: .75rem; top: 50%; transform: translateY(-50%); }
.sidebar__footer { padding: .75rem 1rem; border-top: 1px solid #374151; font-size: .85rem; }
.sidebar__status { margin-bottom: .5rem; color: #fbbf24; }
.sidebar__signout { color: #9ca3af; }
.sidebar__signout:hover { color: #f9fafb; }

.dashboard-main { margin-left: var(--sidebar-width); flex: 1; padding: 2rem; max-width: 960px; }

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  padding: .55rem 1.25rem;
  border-radius: var(--radius);
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  border: 1.5px solid transparent;
  text-decoration: none;
  transition: background .15s, border-color .15s, box-shadow .15s, transform .1s;
  white-space: nowrap;
  font-family: var(--font-sans);
  letter-spacing: -.01em;
}
.btn:hover { text-decoration: none; }
.btn--primary { background: var(--color-primary); color: #fff; border-color: var(--color-primary); }
.btn--primary:hover { background: var(--color-primary-dk); border-color: var(--color-primary-dk); }
.btn--cta { background: var(--color-cta); color: #fff; border-color: var(--color-cta); }
.btn--cta:hover { background: var(--color-cta-dk); border-color: var(--color-cta-dk); }
.btn--secondary { background: transparent; color: var(--color-primary); border-color: var(--color-primary); }
.btn--secondary:hover { background: var(--color-primary-lt); }
.btn--ghost { background: transparent; color: var(--color-muted); border-color: var(--color-border); }
.btn--ghost:hover { background: var(--color-bg); color: var(--color-text); border-color: #d1d0e8; }
.btn--success { background: var(--color-success); color: #fff; border-color: var(--color-success); }
.btn--danger  { background: var(--color-danger);  color: #fff; border-color: var(--color-danger); }
.btn--small  { padding: .3rem .75rem; font-size: .8rem; }
.btn--lg, .btn--large { padding: .75rem 1.6rem; font-size: 1rem; }
.btn--block  { display: flex; width: 100%; }

button.btn { }
input[type="submit"].btn { font-family: inherit; }

/* === Forms === */
.form-control {
  display: block;
  width: 100%;
  padding: .55rem .85rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius);
  font-size: .9rem;
  font-family: var(--font-sans);
  background: #fff;
  color: var(--color-text);
  transition: border-color .15s, box-shadow .15s;
}
.form-control:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(249,115,22,.15);
}
.form-control--sm { padding: .35rem .7rem; font-size: .85rem; }

.form-group { margin-bottom: 1.1rem; }
.form-group label {
  display: block;
  font-size: .82rem;
  font-weight: 600;
  margin-bottom: .35rem;
  color: #374151;
  letter-spacing: -.01em;
}
.form-group--action { display: flex; align-items: flex-end; }

.form-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.form-row .form-group { flex: 1; min-width: 160px; }

.help-text { font-size: .8rem; color: var(--color-muted); margin-top: .3rem; }

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: .4rem .75rem;
}
.checkbox-label { display: flex; align-items: center; gap: .4rem; font-size: .85rem; cursor: pointer; }

/* === Page Header === */
.page-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.75rem;
  flex-wrap: wrap;
}
.page-header h1 { flex: 1; }

/* === Stats Row === */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 3px solid var(--color-primary);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow-sm);
}
.stat-card--highlight { border-left-color: var(--color-cta); }
.stat-card__value { font-size: 1.8rem; font-weight: 700; line-height: 1; color: var(--color-primary); }
.stat-card__label { font-size: .8rem; color: var(--color-muted); margin-top: .3rem; }

/* === Dashboard Section === */
.dashboard-section {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.35rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-sm);
}
.dashboard-section h2 { margin-bottom: .85rem; }

/* === Tables === */
.data-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.data-table th, .data-table td { padding: .65rem .75rem; text-align: left; border-bottom: 1px solid var(--color-border); }
.data-table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--color-muted); font-weight: 600; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--color-bg); }

/* === Banners === */
.banner { padding: .9rem 1.1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .875rem; }
.banner--warning { background: #fef9c3; color: #713f12; border: 1px solid #fde047; }
.banner--info    { background: var(--color-primary-tint); color: var(--color-primary-dk); border: 1px solid var(--color-primary-lt); }

/* === Avatars === */
.avatar { border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar--sm  { width: 36px;  height: 36px; }
.avatar--md  { width: 56px;  height: 56px; }
.avatar--lg  { width: 80px;  height: 80px; }
.avatar--xl  { width: 120px; height: 120px; }
.avatar--sq  { border-radius: var(--radius); }
.avatar--placeholder {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dk));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1em;
}

/* === Tags & Badges === */
.tag {
  display: inline-block;
  padding: .2rem .6rem;
  background: var(--color-primary-lt);
  color: var(--color-primary);
  border-radius: var(--radius-xl);
  font-size: .78rem;
  font-weight: 600;
}
.tag--success   { background: #d1fae5; color: #065f46; }
.tag--warning   { background: #fef9c3; color: #713f12; }
.tag--secondary { background: #f3f4f6; color: #374151; }

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--color-danger);
  color: #fff;
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 700;
}

.tag-cloud { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .4rem; }

/* === Tier Badges === */
.tier-badge {
  display: inline-block;
  padding: .2rem .6rem;
  border-radius: var(--radius-xl);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
}
.tier-badge--community { background: #f3f4f6; color: #6b7280; }
.tier-badge--certified { background: var(--color-primary-lt); color: var(--color-primary); }
.tier-badge--elite     { background: #fef9c3; color: #92400e; }

/* === Status Badges === */
.status-badge {
  display: inline-block;
  padding: .25rem .7rem;
  border-radius: var(--radius-xl);
  font-size: .78rem;
  font-weight: 600;
}
.status-badge--pending       { background: #fef9c3; color: #713f12; }
.status-badge--confirmed     { background: #d1fae5; color: #065f46; }
.status-badge--completed     { background: var(--color-primary-lt); color: var(--color-primary-dk); }
.status-badge--cancelled     { background: #fee2e2; color: #7f1d1d; }
.status-badge--expired       { background: #f3f4f6; color: #6b7280; }
.status-badge--disputed      { background: #ede9fe; color: #4c1d95; }
.status-badge--no_show       { background: #ffedd5; color: #7c2d12; }
.status-badge--approved      { background: #d1fae5; color: #065f46; }
.status-badge--rejected      { background: #fee2e2; color: #7f1d1d; }

/* === Action Bar === */
.action-bar { display: flex; gap: .75rem; align-items: center; padding: 1rem 0; flex-wrap: wrap; }

/* === Browse Layout === */
.browse-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 2rem;
  align-items: start;
}

.browse-filters {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.35rem;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 72px;
}
.browse-filters__title {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--color-muted);
  margin-bottom: 1.1rem;
}

.filter-group { margin-bottom: 1rem; }
.filter-group:last-of-type { margin-bottom: 1.25rem; }
.filter-group__label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: .35rem;
}

.browse-main { min-width: 0; }

/* === Tutor Grid === */
.tutor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2rem;
}

/* === Tutor Card === */
.tutor-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s, transform .2s;
}
.tutor-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.tutor-card__link { display: block; padding: 1.35rem; color: inherit; text-decoration: none; }
.tutor-card__link:hover { text-decoration: none; }

.tutor-card__avatar { margin-bottom: .9rem; position: relative; }
.tutor-card__avatar .avatar {
  width: 72px;
  height: 72px;
  border-radius: var(--radius);
}
.tutor-card__badge {
  position: absolute;
  top: -4px; right: -4px;
  background: var(--color-cta);
  color: #fff;
  border-radius: 10px;
  font-size: .7rem;
  font-weight: 700;
  padding: .1rem .4rem;
}

.tutor-card__name-row { display: flex; align-items: center; gap: .4rem; margin-bottom: .3rem; }
.tutor-card__name { font-size: .95rem; font-weight: 700; color: var(--color-text); }
.tutor-card__flag { font-size: 1rem; line-height: 1; }

.tutor-card__meta { display: flex; align-items: center; gap: .5rem; margin-bottom: .6rem; }
.tutor-card__rating { font-size: .82rem; font-weight: 600; color: #d97706; }

.tutor-card__bio {
  font-size: .83rem;
  color: var(--color-muted);
  line-height: 1.5;
  margin-bottom: .75rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tutor-card__skills { display: flex; flex-wrap: wrap; gap: .3rem; margin-bottom: .75rem; }

.tutor-card__rates {
  font-size: .88rem;
  font-weight: 700;
  color: var(--color-primary);
  padding-top: .75rem;
  border-top: 1px solid var(--color-border);
}

/* === Pagination === */
.pagination { display: flex; justify-content: center; margin-top: 1.5rem; }

/* === Public Profile — Two-column layout === */
.public-profile { padding-bottom: 4rem; }

.public-profile__layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 2.5rem;
  align-items: start;
}

.public-profile__content { min-width: 0; }

.public-profile__sidebar { position: sticky; top: 80px; }

/* Booking widget (sticky sidebar card) */
.booking-widget {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

.booking-widget__avatar { display: flex; justify-content: center; margin-bottom: 1rem; }
.booking-widget__avatar .avatar { width: 80px; height: 80px; border-radius: var(--radius); }
.booking-widget__avatar .avatar--placeholder { font-size: 1.6rem; }

.booking-widget__name {
  text-align: center;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: .35rem;
}

.booking-widget__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  margin-bottom: 1.25rem;
}

.booking-widget__rating { font-size: .85rem; font-weight: 600; color: #d97706; }

.booking-widget__rates {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-bottom: 1.35rem;
  padding: 1rem;
  background: var(--color-bg);
  border-radius: var(--radius);
}
.booking-widget__rate-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .875rem;
}
.booking-widget__rate-row strong { font-weight: 700; color: var(--color-primary); }

.booking-widget__ctas { display: flex; flex-direction: column; gap: .6rem; }

/* Profile heading (inside content column) */
.public-profile__heading { margin-bottom: 1.75rem; }

.public-profile__name-row {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin-bottom: .4rem;
  flex-wrap: wrap;
}
.public-profile__flag { font-size: 1.2rem; }

.public-profile__rating {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-weight: 600;
  color: #d97706;
  font-size: .95rem;
  margin-bottom: .6rem;
}
.public-profile__rating .muted { color: var(--color-muted); font-weight: 400; font-size: .875rem; }

.public-profile__bio {
  font-size: .95rem;
  color: #374151;
  line-height: 1.75;
}

/* === Profile Sections === */
.profile-section {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.35rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
}
.profile-section h2 { margin-bottom: .85rem; }

/* === Rate Badges === */
.rate-badge {
  padding: .35rem .9rem;
  background: var(--color-primary-tint);
  border: 1px solid var(--color-primary-lt);
  border-radius: var(--radius-xl);
  font-weight: 700;
  font-size: .88rem;
  color: var(--color-primary);
}

/* === Availability Slots === */
.slot-grid { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .5rem; }

.slot-chip {
  padding: .35rem .8rem;
  background: var(--color-primary-tint);
  border: 1px solid var(--color-primary-lt);
  border-radius: var(--radius-xl);
  font-size: .8rem;
  color: var(--color-primary);
  font-weight: 600;
  white-space: nowrap;
}

.slot-grid__hint { font-size: .78rem; color: var(--color-muted); margin-top: .35rem; }

/* Selectable slot chips (booking form) */
.slot-day { margin-bottom: 1rem; }
.slot-day strong { display: block; font-size: .82rem; color: var(--color-muted); margin-bottom: .4rem; font-weight: 600; }
.slot-chips { display: flex; flex-wrap: wrap; gap: .4rem; }
.slot-chips--selectable .slot-chip--radio { cursor: pointer; display: flex; align-items: center; gap: .3rem; }
.slot-chips--selectable input[type="radio"] { accent-color: var(--color-primary); }
.slot-chips--selectable input[type="radio"]:checked + span,
.slot-chips--selectable .slot-chip--radio:has(input:checked) {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

/* === Review Cards === */
.review-list { display: flex; flex-direction: column; gap: .85rem; }

.review-card {
  padding: 1rem 1.1rem;
  background: var(--color-bg);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}
.review-card__header { display: flex; align-items: center; gap: .75rem; margin-bottom: .5rem; }
.review-card__rating { color: #f59e0b; font-size: .9rem; letter-spacing: .05em; }
.review-card__date { font-size: .78rem; color: var(--color-muted); margin-left: auto; }
.review-card__comment { font-size: .875rem; color: #374151; line-height: 1.65; }

/* === Credential List === */
.credential-list { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.credential-list li { font-size: .9rem; }

/* === Video Grid === */
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; margin-top: .5rem; }
.video-embed__frame { width: 100%; height: 160px; border: 0; border-radius: var(--radius); }

/* === Conversation List === */
.conversation-list { list-style: none; }
.conversation-list__item { border-bottom: 1px solid var(--color-border); }
.conversation-list__item a { display: flex; align-items: center; gap: .75rem; padding: .85rem .5rem; text-decoration: none; color: inherit; }
.conversation-list__item a:hover { background: var(--color-bg); }
.conversation-list__item--unread .conversation-list__header strong { color: var(--color-primary); }
.conversation-list__body { flex: 1; min-width: 0; }
.conversation-list__header { display: flex; align-items: center; gap: .5rem; margin-bottom: .15rem; }
.conversation-list__time { margin-left: auto; font-size: .8rem; color: var(--color-muted); }
.conversation-list__preview { font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--color-muted); }

/* === Chat Thread === */
.chat-thread {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  padding: 1rem 0;
  max-height: 480px;
  overflow-y: auto;
}
.chat-message { display: flex; flex-direction: column; max-width: 68%; }
.chat-message--tutor  { align-self: flex-end; }
.chat-message--learner { align-self: flex-start; }
.chat-message__bubble { padding: .65rem .9rem; border-radius: 16px; font-size: .9rem; line-height: 1.5; }
.chat-message--tutor .chat-message__bubble   { background: var(--color-primary); color: #fff; border-bottom-right-radius: 4px; }
.chat-message--learner .chat-message__bubble { background: #f3f4f6; color: var(--color-text); border-bottom-left-radius: 4px; }
.chat-message__meta { font-size: .75rem; color: var(--color-muted); margin-top: .2rem; align-self: flex-end; }
.chat-message--learner .chat-message__meta { align-self: flex-start; }
.chat-message__attachment { margin-top: .4rem; }
.chat-message__image { max-width: 220px; border-radius: var(--radius); display: block; }
.chat-message__file {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .82rem; font-weight: 500;
  background: rgba(0,0,0,.06); border-radius: var(--radius-sm);
  padding: .3rem .6rem; color: inherit;
}
.chat-message__file:hover { background: rgba(0,0,0,.1); }

.chat-compose { border-top: 1px solid var(--color-border); padding-top: 1rem; }
.chat-compose__input { margin-bottom: .5rem; }
.chat-compose__actions { display: flex; justify-content: flex-end; }

/* === Completeness Bar === */
.completeness-bar { margin-bottom: 1.25rem; }
.completeness-bar__label { font-size: .85rem; margin-bottom: .3rem; font-weight: 500; }
.completeness-bar__track { height: 8px; background: var(--color-border); border-radius: 4px; overflow: hidden; }
.completeness-bar__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--color-primary), #fb923c);
  border-radius: 4px;
  transition: width .4s;
}

/* === Profile Preview (learner/tutor profile edit) === */
.profile-preview { display: flex; gap: 1.5rem; align-items: flex-start; margin-bottom: 1.5rem; flex-wrap: wrap; }
.profile-preview__meta { display: flex; gap: 1.5rem; margin: .75rem 0; font-size: .9rem; }
.avatar-edit { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }

/* === Session List === */
.session-list { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.session-list__item { display: flex; align-items: center; gap: .75rem; padding: .5rem 0; border-bottom: 1px solid var(--color-border); font-size: .9rem; }
.session-list__time { font-weight: 600; min-width: 50px; }
.session-list__type { color: var(--color-muted); }

/* === Booking Cards === */
.booking-list { display: flex; flex-direction: column; gap: .85rem; }
.booking-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .15s;
}
.booking-card:hover { box-shadow: var(--shadow); }
.booking-card--past { opacity: .75; }
.booking-card__tutor { display: flex; align-items: center; gap: .6rem; font-weight: 600; min-width: 160px; }
.booking-card__meta  { flex: 1; font-size: .85rem; color: var(--color-muted); }
.booking-card__status { min-width: 100px; }
.booking-card__actions { margin-left: auto; }

/* === Detail Grid === */
.detail-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.detail-grid__item label {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--color-muted);
  margin-bottom: .2rem;
  font-weight: 600;
}
.detail-grid__item span { font-weight: 500; }

/* === Booking Form Layout === */
.booking-form-layout { display: flex; gap: 2rem; align-items: flex-start; flex-wrap: wrap; }
.booking-form-layout__tutor { width: 200px; flex-shrink: 0; text-align: center; }
.booking-form-layout__form { flex: 1; min-width: 300px; }
.rate-options { margin: .75rem 0; display: flex; flex-direction: column; gap: .4rem; }
.rate-option { padding: .55rem .85rem; border-radius: var(--radius); background: var(--color-bg); font-size: .875rem; border: 1.5px solid transparent; }
.rate-option--active { background: var(--color-primary-tint); color: var(--color-primary); font-weight: 600; border-color: var(--color-primary-lt); }

.btn-toggle { display: flex; gap: .5rem; flex-wrap: wrap; }
.booking-summary { margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--color-border); }

/* === Integration Status === */
.integration-status { display: flex; align-items: center; gap: .5rem; padding: .75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .875rem; }
.integration-status--connected    { background: #d1fae5; color: #065f46; }
.integration-status--disconnected { background: #fee2e2; color: #7f1d1d; }

/* === Toggle Row === */
.toggle-row { display: flex; align-items: center; justify-content: space-between; padding: .6rem 0; border-bottom: 1px solid var(--color-border); font-size: .9rem; }
.toggle-row:last-child { border-bottom: none; }
.toggle { width: 40px; height: 22px; accent-color: var(--color-primary); }

/* === Welcome / Marketing Page === */
.welcome-page { max-width: 760px; margin: 0 auto; padding: 2rem 1rem; }
.hero { text-align: center; padding: 3rem 0 2.5rem; }
.hero h1 { font-size: 2.4rem; margin-bottom: .5rem; letter-spacing: -.03em; }
.hero__tagline { font-size: 1.1rem; color: var(--color-muted); margin-bottom: 1.75rem; }
.hero__subtext { font-size: .85rem; color: var(--color-muted); margin-top: .75rem; }

.value-props { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1.25rem; margin: 2rem 0; }
.value-prop {
  padding: 1.25rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.value-prop h3 { font-size: .95rem; margin-bottom: .35rem; }
.value-prop p  { font-size: .85rem; color: var(--color-muted); }

.how-it-works { margin: 2rem 0; }
.how-it-works ol { padding-left: 1.25rem; display: flex; flex-direction: column; gap: .5rem; }
.how-it-works li { font-size: .9rem; }

/* === Application Flow (Onboarding) === */
.application-container { max-width: 680px; margin: 0 auto; padding: 2rem 1rem; }
.step-nav { display: flex; gap: .25rem; margin-bottom: 2rem; flex-wrap: wrap; }
.step-nav__item {
  padding: .35rem .9rem;
  border-radius: var(--radius-xl);
  font-size: .8rem;
  font-weight: 600;
  background: #f3f4f6;
  color: var(--color-muted);
}
.step-nav__item--active { background: var(--color-primary); color: #fff; }
.step-nav__item--done   { background: #d1fae5; color: #065f46; }
.step-content { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1.75rem; box-shadow: var(--shadow-sm); }

/* === Top Up === */
.top-up-options { display: flex; gap: .75rem; flex-wrap: wrap; margin: 1.25rem 0; }
.top-up-option { flex: 1; min-width: 90px; text-align: center; }
.divider { text-align: center; color: var(--color-muted); font-size: .85rem; margin: 1rem 0; position: relative; }
.divider::before, .divider::after { content: ""; position: absolute; top: 50%; width: 42%; height: 1px; background: var(--color-border); }
.divider::before { left: 0; }
.divider::after  { right: 0; }

/* === Misc === */
.muted         { color: var(--color-muted); }
.text--success { color: var(--color-success); }
.text--danger  { color: var(--color-danger); }
.text--warning { color: var(--color-warning); }

.empty-state { text-align: center; padding: 3.5rem 1rem; color: var(--color-muted); }
.empty-state h2 { color: var(--color-text); margin-bottom: .5rem; }

/* === Responsive === */
@media (max-width: 860px) {
  .browse-layout {
    grid-template-columns: 1fr;
  }
  .browse-filters {
    position: static;
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    padding: 1rem;
  }
  .filter-group { margin-bottom: 0; min-width: 140px; flex: 1; }
  .filter-group:last-of-type { margin-bottom: 0; }

  .public-profile__layout {
    grid-template-columns: 1fr;
  }
  .public-profile__sidebar {
    position: static;
    order: -1;
  }
}

@media (max-width: 640px) {
  .dashboard-layout { flex-direction: column; }
  .sidebar { position: static; width: 100%; flex-direction: row; flex-wrap: wrap; }
  .dashboard-main { margin-left: 0; padding: 1rem; }
  .form-row { flex-direction: column; }
  .booking-form-layout { flex-direction: column; }
  .booking-form-layout__tutor { width: 100%; }
  .tutor-grid { grid-template-columns: 1fr 1fr; gap: .85rem; }
  h1 { font-size: 1.4rem; }
  .learner-layout main { padding: 1.25rem 1rem; }
  .onboarding__step-label { display: none; }
  .onboarding__step-connector { margin-top: 15px; }
}

/* =============================================
   Onboarding Quiz
   ============================================= */

.onboarding {
  max-width: 600px;
  margin: 0 auto;
  padding: 2rem 1rem 3rem;
}

/* === Step progress tabs === */
.onboarding__progress {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2.5rem;
}

.onboarding__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .4rem;
  flex-shrink: 0;
}

.onboarding__step-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  font-weight: 700;
  transition: all .2s;
}

.onboarding__step-label {
  font-size: .72rem;
  font-weight: 600;
  color: var(--color-muted);
  white-space: nowrap;
  transition: color .2s;
}

.onboarding__step--active .onboarding__step-dot {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #fff;
  box-shadow: 0 0 0 4px rgba(249,115,22,.18);
}
.onboarding__step--active .onboarding__step-label {
  color: var(--color-primary);
  font-weight: 700;
}

.onboarding__step--done .onboarding__step-dot {
  background: var(--color-success);
  border-color: var(--color-success);
  color: #fff;
}
.onboarding__step--done .onboarding__step-label { color: var(--color-muted); }

.onboarding__step-connector {
  flex: 1;
  height: 2px;
  background: var(--color-border);
  margin-top: 15px;
  align-self: flex-start;
}
.onboarding__step-connector--done { background: var(--color-success); }

/* === Step content === */
.quiz-step {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.5rem;
}

.quiz-step__title { font-size: 1.25rem; font-weight: 700; margin-bottom: .35rem; letter-spacing: -.02em; }
.quiz-step__hint  { font-size: .875rem; color: var(--color-muted); margin-bottom: 1.25rem; }

/* === Skill chips (step 1) === */
.skill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: .6rem;
  margin-top: 1rem;
}

.skill-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .65rem 1rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  cursor: pointer;
  font-size: .875rem;
  font-weight: 600;
  color: var(--color-text);
  background: var(--color-surface);
  transition: border-color .15s, background .15s, color .15s;
  text-align: center;
  line-height: 1.3;
}
.skill-chip input[type="radio"] { display: none; }
.skill-chip:hover { border-color: var(--color-primary-lt); background: var(--color-primary-tint); }
.skill-chip--selected {
  border-color: var(--color-primary);
  background: var(--color-primary-tint);
  color: var(--color-primary);
}

/* === Option cards (steps 2–5) === */
.option-list { display: flex; flex-direction: column; gap: .6rem; margin-top: 1rem; }

.option-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: .9rem;
  font-weight: 500;
  color: var(--color-text);
  background: var(--color-surface);
  transition: border-color .15s, background .15s;
  border-left-width: 3px;
}
.option-card:hover { border-color: var(--color-primary-lt); background: var(--color-primary-tint); }

.option-card input[type="radio"],
.option-card input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  accent-color: var(--color-primary);
}

.option-card--selected {
  border-color: var(--color-primary);
  background: var(--color-primary-tint);
  border-left-color: var(--color-primary);
}

/* Budget tier cards — stacked content inside */
.option-card--budget { align-items: flex-start; }
.option-card--budget input[type="radio"] { margin-top: .2rem; }

.option-card__range {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-left: .5rem;
}

.option-card__desc {
  font-size: .82rem;
  color: var(--color-muted);
  margin-top: .3rem;
  font-weight: 400;
  line-height: 1.5;
}

/* === Onboarding nav buttons === */
.onboarding__actions {
  display: flex;
  align-items: center;
  gap: .75rem;
}
.onboarding__actions .btn--primary { margin-left: auto; }

.onboarding__skip {
  font-size: .82rem;
  color: var(--color-muted);
  margin-left: auto;
}
.onboarding__skip:hover { color: var(--color-text); }

/* =============================================
   Package Purchase Cards
   ============================================= */

.package-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.package-card {
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.25rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: .6rem;
  position: relative;
  transition: box-shadow .2s, border-color .2s;
}
.package-card:hover { box-shadow: var(--shadow-md); }

/* Featured / Most Popular card */
.package-card--featured {
  border-color: var(--color-cta);
  box-shadow: 0 0 0 3px rgba(249,115,22,.15), var(--shadow-md);
}

.package-card__badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-cta);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: .2rem .75rem;
  border-radius: var(--radius-xl);
  white-space: nowrap;
}

.package-card__sessions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .1rem;
}
.package-card__count {
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1;
  color: var(--color-primary);
  letter-spacing: -.03em;
}
.package-card--featured .package-card__count { color: var(--color-cta); }
.package-card__label {
  font-size: .8rem;
  font-weight: 600;
  color: var(--color-muted);
  text-transform: uppercase;
  letter-spacing: .05em;
}

.package-card__type {
  font-size: .82rem;
  color: var(--color-muted);
  padding: .25rem .6rem;
  background: var(--color-bg);
  border-radius: var(--radius-xl);
  display: inline-block;
}

.package-card__price {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -.02em;
}

.package-card__per-session {
  font-size: .8rem;
  color: var(--color-muted);
  margin-bottom: .25rem;
}

/* Package status banner (booking form) */
.package-status {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: .85rem 1.1rem;
  background: var(--color-primary-tint);
  border: 1px solid var(--color-primary-lt);
  border-radius: var(--radius);
  margin-bottom: 1.25rem;
  font-size: .875rem;
  flex-wrap: wrap;
}
.package-status strong { color: var(--color-primary); font-weight: 700; }

/* =============================================
   Booking Detail — Review & Lesson Notes
   ============================================= */

.review-display {
  display: flex;
  flex-direction: column;
  gap: .5rem;
}

.rating { display: flex; gap: .15rem; }
.star { color: #f59e0b; font-size: 1.1rem; }

.lesson-conclusion {
  font-size: .9rem;
  line-height: 1.75;
  color: #374151;
  background: var(--color-bg);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  border-left: 3px solid var(--color-primary-lt);
}
.lesson-conclusion p { margin-bottom: .5rem; }
.lesson-conclusion p:last-child { margin-bottom: 0; }

/* =============================================
   Messages
   ============================================= */

/* Chat compose footer (send + attachment row) */
.chat-compose__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.chat-compose__attach {
  display: flex;
  align-items: center;
  gap: .35rem;
  font-size: .8rem;
  color: var(--color-muted);
  cursor: pointer;
}
.chat-compose__attach:hover { color: var(--color-primary); }

.chat-compose__file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

/* =============================================
   Learner Profile
   ============================================= */

.profile-preview__body { flex: 1; min-width: 0; }
.profile-preview__body h2 { margin-bottom: .35rem; }
.profile-preview__body p  { font-size: .9rem; margin-bottom: .25rem; }

/* =============================================
   Recommendations
   ============================================= */

.recommendations__header { margin-bottom: 1.75rem; }
.recommendations__header h1 { margin-bottom: .3rem; }

.recommendations__browse {
  margin-top: 2rem;
  text-align: center;
}

/* =============================================
   Auth Pages (Login / Registration)
   ============================================= */

.auth-card {
  max-width: 420px;
  margin: 3rem auto;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem 2rem 1.5rem;
  box-shadow: var(--shadow-md);
}

.auth-card__title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  letter-spacing: -.02em;
}

.auth-card__footer {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--color-border);
  font-size: .85rem;
  color: var(--color-muted);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: .4rem;
}

/* Devise default .field / .actions wrappers */
.field {
  margin-bottom: 1rem;
}
.field p { margin: 0; }
.field p + p { margin-top: .3rem; }
.field label,
.field > label {
  display: block;
  font-size: .82rem;
  font-weight: 600;
  margin-bottom: .3rem;
  color: #374151;
}
.field input[type="email"],
.field input[type="password"],
.field input[type="text"] {
  display: block;
  width: 100%;
  padding: .55rem .85rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius);
  font-size: .9rem;
  font-family: var(--font-sans);
  background: #fff;
  color: var(--color-text);
  transition: border-color .15s, box-shadow .15s;
}
.field input[type="email"]:focus,
.field input[type="password"]:focus,
.field input[type="text"]:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(249,115,22,.15);
}
.field--checkbox { margin-top: .5rem; }

/* Devise .actions wrapper */
.actions { margin-top: 1.25rem; }
.actions input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: .6rem 1.25rem;
  background: var(--color-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: .9rem;
  font-weight: 600;
  font-family: var(--font-sans);
  cursor: pointer;
  transition: background .15s;
}
.actions input[type="submit"]:hover { background: var(--color-primary-dk); }

/* Form-level components */
.form-hint  { font-size: .8rem; color: var(--color-muted); margin-bottom: .3rem; }
.form-error { font-size: .8rem; color: var(--color-danger); margin-top: .25rem; display: block; }

/* .form-actions (review form, etc.) */
.form-actions { display: flex; gap: .75rem; align-items: center; margin-top: 1.25rem; }

/* =============================================
   Star Rating Widget (review form)
   ============================================= */

.star-rating {
  display: flex;
  flex-direction: row-reverse;
  gap: .15rem;
  margin-top: .4rem;
}

.star-rating__label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .15rem;
  cursor: pointer;
}
.star-rating__label input[type="radio"] { display: none; }

.star-rating__star {
  font-size: 2rem;
  color: var(--color-border);
  line-height: 1;
  transition: color .1s, transform .1s;
}
.star-rating__num {
  font-size: .68rem;
  color: var(--color-muted);
}

/* Checked state: fill selected star + all lower-numbered ones (which appear later in DOM) */
.star-rating__label:has(input:checked) .star-rating__star,
.star-rating__label:has(input:checked) ~ .star-rating__label .star-rating__star {
  color: #f59e0b;
}

/* Hover: fill hovered star + all lower ones */
.star-rating:hover .star-rating__label .star-rating__star { color: var(--color-border); }
.star-rating__label:hover .star-rating__star,
.star-rating__label:hover ~ .star-rating__label .star-rating__star {
  color: #fbbf24;
  transform: scale(1.1);
}

/* Review form wrapper */
.review-form {
  max-width: 560px;
}

/* =============================================
   Home Page
   ============================================= */

/* === Page: Home (dark topnav + full-bleed layout) === */
.page--home .topnav {
  background: #1c1917;
  border-bottom-color: rgba(255,255,255,.08);
  box-shadow: none;
}
.page--home .topnav__brand { color: #fff; }
.page--home .topnav__brand:hover { color: rgba(255,255,255,.85); }
.page--home .topnav__links a { color: rgba(255,255,255,.6); }
.page--home .topnav__links a:hover { color: #fff; }
.page--home .topnav__user { color: #fff !important; }
.page--home .topnav__lang-sep { color: rgba(255,255,255,.25); }
.page--home .topnav__lang-btn { color: rgba(255,255,255,.45); }
.page--home .topnav__lang-btn:hover { color: #fff; border-color: rgba(255,255,255,.2); }
.page--home .topnav__lang-btn--active {
  background: rgba(249,115,22,.2);
  color: var(--color-primary);
  border-color: rgba(249,115,22,.3);
}
.page--home main { padding: 0; max-width: none; }

/* === Landing: Hero === */
.landing-hero {
  background: #1c1917;
  padding: 5.5rem 1.5rem 6.5rem;
  position: relative;
  overflow: hidden;
}
.landing-hero::before {
  content: "";
  position: absolute;
  top: -160px; right: -80px;
  width: 640px; height: 640px;
  background: radial-gradient(circle, rgba(249,115,22,.11) 0%, transparent 65%);
  pointer-events: none;
}
.landing-hero::after {
  content: "";
  position: absolute;
  bottom: -100px; left: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(249,115,22,.06) 0%, transparent 65%);
  pointer-events: none;
}
.landing-hero__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 1;
}
.landing-hero__headline {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  line-height: 1.12;
  color: #fff;
  letter-spacing: -.01em;
  margin-bottom: 1.25rem;
}
.landing-hero__accent {
  color: var(--color-primary);
  font-style: italic;
}
.landing-hero__sub {
  font-size: 1.05rem;
  color: rgba(255,255,255,.58);
  line-height: 1.8;
  margin-bottom: 2.25rem;
}
.landing-hero__ctas { display: flex; gap: 1rem; flex-wrap: wrap; }
.btn--hero-ghost {
  background: transparent;
  color: rgba(255,255,255,.8);
  border-color: rgba(255,255,255,.22);
}
.btn--hero-ghost:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.38); }

/* Hero visual: floating tutor cards */
.landing-hero__visual {
  position: relative;
  height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1.1rem;
}
.landing-hero__glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(249,115,22,.14) 0%, transparent 70%);
  pointer-events: none;
}
.landing-hero__avatar-card {
  display: flex;
  align-items: center;
  gap: .85rem;
  background: rgba(255,255,255,.07);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-xl);
  padding: .7rem 1.1rem;
  min-width: 220px;
  animation: floatCard 7s ease-in-out infinite;
}
.landing-hero__avatar-card:nth-child(2) { animation-delay: -2.3s; align-self: flex-end; }
.landing-hero__avatar-card:nth-child(3) { animation-delay: -4.6s; align-self: flex-start; }
@keyframes floatCard {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}
.landing-hero__avatar-img {
  width: 48px; height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(249,115,22,.5);
  flex-shrink: 0;
}
.landing-hero__avatar-placeholder {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-primary), #fb923c);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; font-weight: 700; color: #fff;
  flex-shrink: 0;
  border: 2px solid rgba(249,115,22,.5);
}
.landing-hero__avatar-info { min-width: 0; }
.landing-hero__avatar-name {
  font-size: .9rem; font-weight: 700; color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.landing-hero__avatar-meta {
  font-size: .77rem;
  color: rgba(255,255,255,.55);
  display: flex; align-items: center; gap: .35rem;
  margin-top: .1rem;
}
.landing-hero__avatar-star { color: var(--color-primary); font-size: .8rem; }

/* === Landing: Stats strip === */
.landing-stats {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: 2.25rem 1.5rem;
}
.landing-stats__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
.landing-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: .5rem 3rem;
  text-align: center;
}
.landing-stat__num {
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 400;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: .3rem;
}
.landing-stat__unit { font-size: 1.5rem; }
.landing-stat__label {
  font-size: .78rem;
  color: var(--color-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
}
.landing-stats__sep {
  width: 1px; height: 48px;
  background: var(--color-border);
  flex-shrink: 0;
}

/* === Landing: How it works === */
.landing-how {
  background: var(--color-bg);
  padding: 5.5rem 1.5rem;
}
.landing-how__inner {
  max-width: var(--content-width);
  margin: 0 auto;
}
.landing-section-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 400;
  text-align: center;
  margin-bottom: 3.5rem;
  letter-spacing: -.01em;
  color: var(--color-text);
}
.landing-how__steps {
  display: flex;
  align-items: flex-start;
}
.landing-how__step {
  flex: 1;
  text-align: center;
  padding: 0 2.25rem;
}
.landing-how__step-num {
  font-family: var(--font-display);
  font-size: 4rem;
  font-weight: 400;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: .6rem;
  opacity: .85;
}
.landing-how__step h3 {
  font-size: 1rem; font-weight: 700;
  margin-bottom: .5rem;
  color: var(--color-text);
}
.landing-how__step p {
  font-size: .875rem;
  color: var(--color-muted);
  line-height: 1.7;
}
.landing-how__connector {
  width: 64px; height: 2px;
  background: repeating-linear-gradient(
    90deg,
    var(--color-primary) 0, var(--color-primary) 7px,
    transparent 7px, transparent 14px
  );
  margin-top: 2.5rem;
  flex-shrink: 0;
  opacity: .35;
}

/* === Landing: Featured tutors === */
.landing-tutors {
  background: var(--color-surface);
  padding: 5.5rem 1.5rem;
  border-top: 1px solid var(--color-border);
}
.landing-tutors__inner {
  max-width: var(--content-width);
  margin: 0 auto;
}
.landing-tutors__more {
  text-align: center;
  margin-top: 2.75rem;
}

/* === Landing: Bottom CTA === */
.landing-cta {
  background: var(--color-primary);
  padding: 5.5rem 1.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.landing-cta::before {
  content: "";
  position: absolute;
  top: -120px; right: -60px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(255,255,255,.1) 0%, transparent 65%);
  pointer-events: none;
}
.landing-cta__inner {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.landing-cta__headline {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 400;
  color: #fff;
  margin-bottom: .75rem;
  letter-spacing: -.01em;
}
.landing-cta__sub {
  font-size: 1.05rem;
  color: rgba(255,255,255,.78);
  margin-bottom: 2.25rem;
  line-height: 1.7;
}
.btn--on-coral {
  background: #1c1917;
  color: #fff;
  border-color: #1c1917;
}
.btn--on-coral:hover { background: #2d2825; border-color: #2d2825; }

/* === Landing: Responsive === */
@media (max-width: 860px) {
  .landing-hero__inner {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .landing-hero__visual { width: 100%; }
  .landing-how__steps {
    flex-direction: column;
    gap: 2rem;
    align-items: center;
  }
  .landing-how__step { padding: 0 1rem; max-width: 340px; }
  .landing-how__connector {
    width: 2px; height: 40px;
    background: repeating-linear-gradient(
      180deg,
      var(--color-primary) 0, var(--color-primary) 7px,
      transparent 7px, transparent 14px
    );
    margin: 0;
  }
  .landing-stat { padding: .5rem 1.5rem; }
  .landing-stats__sep { display: none; }
}

/* =============================================
   Auth Split Layout (sign-in / sign-up)
   ============================================= */

.auth-split {
  display: flex;
  min-height: 100vh;
}

/* --- Left brand panel --- */
.auth-split__brand {
  flex: 0 0 44%;
  background: #1c1917;
  display: flex;
  flex-direction: column;
  padding: 2.5rem 3rem;
}

.auth-split__brand-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.auth-brand-logo {
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--color-primary);
  text-decoration: none;
  letter-spacing: -.02em;
}
.auth-brand-logo:hover { text-decoration: none; color: var(--color-primary); }

.auth-brand-headline {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 5rem;
}

.auth-brand-label {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: rgba(255,255,255,.3);
  margin-bottom: 2rem;
}

.auth-brand-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 3.2vw, 3.6rem);
  font-weight: 400;
  line-height: 1.1;
  color: #ffffff;
  margin-bottom: 1.25rem;
  letter-spacing: -.01em;
}

.auth-brand-title em {
  font-style: italic;
  color: var(--color-primary);
}

.auth-brand-tagline {
  font-size: .88rem;
  line-height: 1.7;
  color: rgba(255,255,255,.4);
  max-width: 30ch;
}

/* --- Right form panel --- */
.auth-split__form {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  background: var(--color-bg);
}

.auth-split__form-inner {
  width: 100%;
  max-width: 390px;
}

.auth-form-header {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 2.5rem;
}

/* Language toggle */
.auth-lang-toggle {
  display: flex;
  align-items: center;
  gap: .15rem;
}

.auth-lang-btn {
  background: none;
  border: none;
  padding: .2rem .3rem;
  font-size: .78rem;
  font-weight: 600;
  color: var(--color-muted);
  cursor: pointer;
  font-family: var(--font-sans);
  border-radius: var(--radius-sm);
  line-height: 1;
}
.auth-lang-btn:hover { color: var(--color-text); }
.auth-lang-btn--active { color: var(--color-text); }

.auth-lang-sep {
  color: var(--color-border);
  font-size: .75rem;
  line-height: 1;
  padding: 0 .1rem;
}

/* Flash inside auth panel */
.auth-split__form .flash {
  margin: 0 0 1.25rem;
}

/* Tabs */
.auth-tabs {
  display: flex;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 1.75rem;
}

.auth-tab {
  padding: .55rem 0;
  margin-right: 1.5rem;
  font-size: .88rem;
  font-weight: 600;
  color: var(--color-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.auth-tab:hover { color: var(--color-text); text-decoration: none; }
.auth-tab--active { color: var(--color-text); border-bottom-color: var(--color-primary); }

/* OAuth buttons */
.oauth-buttons {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-bottom: 1.25rem;
}

.oauth-buttons form {
  display: contents;
}

.oauth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  width: 100%;
  padding: .6rem 1rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  font-size: .845rem;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  font-family: var(--font-sans);
  text-decoration: none;
  line-height: 1;
  letter-spacing: -.01em;
}
.oauth-btn:hover {
  border-color: #c5bbb3;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: var(--color-text);
}
.oauth-btn svg { flex-shrink: 0; }

/* Divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: .7rem;
  margin: 1.25rem 0;
  color: var(--color-muted);
  font-size: .77rem;
  font-weight: 500;
  letter-spacing: .01em;
  text-transform: uppercase;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

/* Error explanation */
#error_explanation {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  border-radius: var(--radius);
  padding: .85rem 1rem;
  margin-bottom: 1.25rem;
  font-size: .84rem;
  color: #7f1d1d;
}
#error_explanation h2 {
  font-size: .84rem;
  font-weight: 600;
  margin-bottom: .35rem;
}
#error_explanation ul {
  padding-left: 1.1rem;
  margin: 0;
}
#error_explanation li { margin-bottom: .1rem; }

/* Auth form footer (forgot pw, etc.) */
.auth-form-footer {
  margin-top: 1.25rem;
  text-align: center;
  font-size: .82rem;
  color: var(--color-muted);
  display: flex;
  flex-direction: column;
  gap: .4rem;
}
.auth-form-footer a { color: var(--color-muted); }
.auth-form-footer a:hover { color: var(--color-text); }

/* Responsive */
@media (max-width: 768px) {
  .auth-split { flex-direction: column; }

  .auth-split__brand {
    flex: 0 0 auto;
    padding: 2rem;
  }

  .auth-brand-headline {
    padding: 1.75rem 0 1.25rem;
  }

  .auth-brand-title { font-size: 2.2rem; }

  .auth-split__form {
    align-items: flex-start;
    padding: 2rem 1.5rem;
  }

  .auth-split__form-inner { max-width: 100%; }
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */
