/* =========================================================
   Hypno University - Mock B
   Neutral dark + feminine accent
   ========================================================= */

/* ---------- Tokens ---------- */

:root {
    /* Fonts */
    --hu-font-body: "Helvetica Neue", Helvetica, Arial, sans-serif;
    --hu-font-heading: "Helvetica Neue", Helvetica, Arial, sans-serif;

    /* Neutral dark palette */
    --hu-bg: #121212;          /* page background */
    --hu-bg-elevated: #121212;

    --hu-surface: #282828;     /* main card/window */
    --hu-surface-soft: #323232;/* subtle alt surface */

    --hu-border-subtle: #1f1f1f;
    --hu-border-strong: #3c3c3c;

    /* Title/header border */
    --hu-border-title: #282828;

    /* Accent colors */
    --hu-accent-main: #e73dcd;       /* primary button + main accent */
    --hu-accent-soft: rgba(207, 28, 158, 0.16);
    --hu-accent-secondary: #f08bc7;  /* lighter magenta for details */
    --hu-accent-gold: #f7d27c;       /* optional tiny highlights */

    /* Text */
    --hu-text-main: #f5f5f5;
    --hu-text-soft: #d0d0d0;
    --hu-text-muted: #aaaaaa;

    /* Shapes */
    --hu-radius-lg: 10px;
    --hu-radius-md: 6px;
    --hu-radius-pill: 999px;   /* buttons stay pill-shaped */

    --hu-nav-height: 72px;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body.hu {
    min-height: 100vh;
    font-family: var(--hu-font-body);
    color: var(--hu-text-main);
    background: var(--hu-bg);
    -webkit-font-smoothing: antialiased;
}

/* Prevent page scroll while a modal/drawer is open */
body.hu.hu-body--lock-scroll {
    overflow: hidden;
}

/* ---------- Background ---------- */

.hu-bg {
    display: none;
}

/* ---------- Shell & layout ---------- */

.hu-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
}

.hu-main {
    flex: 1;
    padding: 1.8rem 0 2.6rem;
}

.hu-container {
    width: min(1450px, 100% - 2.5rem);
    margin: 0 auto;
}

/* ---------- Network bar ---------- */

.hu-network {
    background: #121212;
    border-bottom: 1px solid #2a2a2a;
    color: #c3c3c3;
    position: relative;
    z-index: 10; /* above base content, below overlay and menu */
}

.hu-network__inner {
    height: 30px;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.75rem;
}

.hu-network__label {
    color: #838383;
    letter-spacing: 0.1em;
    font-size: 0.7rem;
}

.hu-network__link {
    color: #c3c3c3;
    text-decoration: none;
    font-size: 0.75rem;
}

.hu-network__link:hover {
    color: #e73dcd;
}

/* ---------- Header & nav ---------- */

.hu-header {
    position: sticky;
    top: 0;
    z-index: 20;   /* above content, below overlay and drawer */
    backdrop-filter: blur(18px);
    background: #222222;
    border-bottom: none;
}

/* FLEX layout: logo | search | right / hamburger */
.hu-header__inner {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    height: var(--hu-nav-height);
    gap: 1.5rem;
}

.hu-header__right {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-left: auto; /* push VIP + user to the far right on desktop */
}

/* Brand */

.hu-brand {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
}

.hu-brand__image {
    height: 36px;
    width: auto;
    display: block;
}

/* Allow header search to shrink properly in flex layouts */
.hu-header-search,
.hu-header-search__input {
    min-width: 0;
}

/* VIP button */

.hu-header__vip {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.hu-header__vip-image {
    height: 32px;
    width: auto;
    display: block;
}

/* Header search */

.hu-header-search {
    flex: 1;
    max-width: 420px;
    margin: 0 0.75rem;
    display: flex;
    align-items: stretch;
}

.hu-header-search__input {
    flex: 1;
    height: 34px;
    border-radius: var(--hu-radius-lg) 0 0 var(--hu-radius-lg);
    padding: 0 0.75rem;
    font-size: 1rem;   /* >=16px to prevent iOS zoom */
    background: #ffffff;
    color: #222222;

    /* keep border consistent so focus doesn't jump */
    border: 1px solid transparent;
    box-shadow: none;
}

.hu-header-search__input::placeholder {
    color: #a0a0a0;
    font-size: 1rem;  /* lock placeholder size */
}

.hu-header-search__input:focus::placeholder,
.hu-header-search__input:focus-visible::placeholder {
    font-size: 1rem;  /* prevent any size change on focus */
}

/* Remove default focus outlines / colored borders */
.hu-header-search__input:focus,
.hu-header-search__input:focus-visible,
.hu-header-search__button:focus,
.hu-header-search__button:focus-visible {
    outline: none;
    box-shadow: none;
    border-color: transparent;  /* no pink/blue border */
}

.hu-header-search__button {
    height: 34px;
    min-width: 56px;
    padding: 0 1.1rem;
    border: none;
    border-radius: 0 var(--hu-radius-lg) var(--hu-radius-lg) 0;
    background: linear-gradient(135deg, #cd7ada, #e939cc);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.hu-header-search__button:hover {
    border: none;
    background: linear-gradient(135deg, #e676f4, #ff48e2);
    color: #ffffff;
}

.hu-header-search__icon {
    font-size: 1rem;
}

.hu-header-search__button i {
    font-size: 1.1rem;
}

/* Screen reader utility */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Nav */

.hu-nav {
    display: flex;
    align-items: center;
}

.hu-nav__list {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

/* Menubar-specific spacing (desktop) */
.hu-menubar .hu-nav__list {
    gap: 1.5rem;
}

.hu-nav__link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.hu-nav__icon {
    font-size: 0.9rem;
    line-height: 1;
}

.hu-nav__label {
    line-height: 1;
}

/* Flat text links */

.hu-nav__link {
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    color: #ffffff;

    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;

    transition: color 150ms ease-out;
}

.hu-nav__link:hover,
.hu-nav__link:focus-visible {
    color: #e73dcd;
}

.hu-nav__link.is-active {
    color: #e73dcd;
}

/* Top-right user */

.hu-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: inherit;
    padding: 0;
    border: none;
    background: none;
}

.hu-user__avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    object-fit: cover;
}

.hu-user__meta {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.hu-user__name {
    font-size: 0.78rem;
    font-weight: 600;
}

.hu-user__stats {
    font-size: 0.7rem;
    color: var(--hu-text-muted);
}

/* Nav toggle (mobile) */

.hu-nav-toggle {
    display: none;
    background: transparent;
    border: none;
    border-radius: 8px;
    padding: 0.25rem;
    cursor: pointer;
}

/* Font Awesome bars icon inside the toggle */
.hu-nav-toggle i {
    font-size: 1.2rem;
    color: var(--hu-text-main);
}

/* ---------- Menubar under header (desktop) ---------- */

.hu-menubar {
    background: #121212;
    border-bottom: 1px solid #373737;
}

.hu-menubar__inner {
    height: 32px;
    display: flex;
    align-items: stretch;
}

/* Nav inside menubar (desktop) */

.hu-menubar .hu-nav {
    display: flex;
    align-items: stretch;
    height: 100%;
}

.hu-menubar .hu-nav__list {
    display: flex;
    align-items: stretch;
    gap: 1.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.hu-menubar .hu-nav__link {
    display: flex;
    align-items: center;
    height: 32px;
}

/* ---------- Footer ---------- */

.hu-footer {
    border-top: 1px solid #4a4a4a;
    background: #121212;
    padding: 0.7rem 0;
    font-size: 0.74rem;
}

.hu-footer__inner {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
}

.hu-footer__label {
    letter-spacing: 0.13em;
    font-size: 0.68rem;
    color: #838383;
}

/* ---------- Sections / general ---------- */

.hu-section {
    margin-bottom: 1.9rem;
}

.hu-section-title {
    margin: 0 0 0.7rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--hu-text-muted);
}

/* ---------- Cards ---------- */

.hu-card {
    background: #1f1f1f;
    border-radius: var(--hu-radius-lg);
    position: relative;
    padding: 1rem 1rem 0.95rem;
    display: flex;
    flex-direction: column;
}

/* Visual border behind content (so images can sit "on top") */
.hu-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid var(--hu-border-subtle);
    pointer-events: none;
    z-index: 0;
}

.hu-card--soft {
    background: #1f1f1f;
}

.hu-card--outline::before {
    border-style: dashed;
}

.hu-card__kicker {
    margin: 0 0 0.25rem;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--hu-text-muted);
}

.hu-card__title {
    margin: 0 0 0.28rem;
    font-family: var(--hu-font-heading);
    font-size: 0.98rem;
}

.hu-card__body {
    margin: 0 0 0.6rem;
    font-size: 0.86rem;
    color: var(--hu-text-soft);
}

.hu-card__body--small {
    font-size: 0.78rem;
}

.hu-card__meta {
    margin: 0;
    font-size: 0.78rem;
    color: var(--hu-text-muted);
}

.hu-card__footer {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    font-size: 0.78rem;
    color: var(--hu-text-muted);
}

/* Links */

.hu-course-card__title,
.hu-course-card__title a {
    color: var(--hu-text-main) !important;
}

.hu-card a:not(.hu-btn):not(.hu-course-card__title-link):not(.hu-course-card__thumb-link):not(.hu-task-card__title-link):not(.hu-training-card__title-link) {
    color: var(--hu-accent-main);
    text-decoration: none;
}

.hu-card a:not(.hu-btn):not(.hu-course-card__title-link):not(.hu-course-card__thumb-link):not(.hu-task-card__title-link):not(.hu-training-card__title-link):hover {
    text-decoration: underline;
}

.hu-course-card a:not(.hu-btn),
.hu-task-card a:not(.hu-btn),
.hu-training-card a:not(.hu-btn) {
    color: var(--hu-text-main);
    text-decoration: none;
}

.hu-course-card a:not(.hu-btn):hover,
.hu-task-card a:not(.hu-btn):hover,
.hu-training-card a:not(.hu-btn):hover {
    color: var(--hu-text-main);
    text-decoration: underline;
}

/* ---------- Buttons & chips ---------- */

.hu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1.1rem;
    border-radius: var(--hu-radius-lg);
    border: 1px solid transparent;
    font-size: 0.78rem;
    font-weight: 550;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition:
        background 180ms ease-out,
        border-color 180ms ease-out,
        transform 120ms ease-out;
}

.hu-btn--primary {
    border: none;
    background: linear-gradient(135deg, #cd7ada, #e939cc);
    color: #ffffff;
}

.hu-btn--primary:hover {
    border: none;
    background: linear-gradient(135deg, #e676f4, #ff48e2);
    color: #ffffff;
}

.hu-btn--ghost {
    background: #1b1b1b;
    border-color: #4a4a4a;
    color: var(--hu-text-main);
}

.hu-btn--ghost:hover {
    background: #252525;
    border-color: #777777;
}

.hu-btn--small {
    padding: 0.38rem 0.9rem;
    font-size: 0.72rem;
}

.hu-btn--full {
    width: 100%;
    justify-content: center;
}

/* Pills */

.hu-pill {
    display: inline-flex;
    align-items: center;
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    padding: 0.2rem 0.6rem;
    font-size: 0.7rem;
    color: var(--hu-text-soft);
    white-space: nowrap;
}

.hu-pill--accent {
    border-color: var(--hu-border-strong);
    color: var(--hu-accent-secondary);
}

/* Chips */

.hu-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.hu-chip {
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    padding: 0.24rem 0.75rem;
    font-size: 0.76rem;
    background: #202020;
    color: var(--hu-text-soft);
    cursor: pointer;
}

.hu-chip.is-active {
    border-color: var(--hu-accent-main);
    background: #2d1a29;
    color: var(--hu-accent-main);
}

/* ---------- Grids & lists ---------- */

.hu-grid {
    display: grid;
    gap: 1.1rem;
}

.hu-grid--2 {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.hu-grid--3 {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

/* ---------- Leaderboards ---------- */

.hu-leaderboards .hu-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hu-list {
    list-style: none;
    padding: 0;
    margin: 0.35rem 0 0;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

.hu-list--bullets {
    list-style: disc;
    padding-left: 1.1rem;
}

.hu-list--leaderboard li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    padding: 0.25rem 0;
}

.hu-rank {
    width: 1.3rem;
    font-weight: 700;
    color: var(--hu-text-main);
}

.hu-name {
    flex: 1;
}

.hu-value {
    color: var(--hu-text-muted);
}

/* Statline */

.hu-statline {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 0.5rem;
    font-size: 0.78rem;
    color: var(--hu-text-soft);
}

.hu-statline span strong {
    color: var(--hu-accent-main);
}

/* ---------- Today progress bar ---------- */

.hu-today-progress {
    margin: 0.75rem 0 0.4rem;
}

.hu-today-progress__bar {
    position: relative;
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: #1b1b1b;
    border: 1px solid var(--hu-border-subtle);
    overflow: hidden;
    margin: 0.25rem 0 0.35rem;
}

.hu-today-progress__fill {
    height: 100%;
    border-radius: inherit;
    background: var(--hu-accent-main);
}

/* ---------- Hero (landing) ---------- */

.hu-section--hero {
    margin-top: 1.5rem;
}

.hu-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.2fr);
    gap: 1.7rem;
    align-items: center;
}

.hu-hero__title {
    margin: 0 0 0.4rem;
    font-family: var(--hu-font-heading);
    font-size: 2rem;
}

.hu-hero__body {
    margin: 0 0 1rem;
    font-size: 0.94rem;
    color: var(--hu-text-soft);
    max-width: 29rem;
}

.hu-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-bottom: 0.5rem;
}

.hu-hero__hint {
    margin: 0;
    font-size: 0.76rem;
    color: var(--hu-text-muted);
}

.hu-hero__panel {
    display: flex;
    justify-content: flex-end;
}

.hu-login {
    max-width: 340px;
}

.hu-login__fields {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.hu-field {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    font-size: 0.78rem;
}

.hu-field label {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--hu-text-muted);
}

.hu-field input {
    border-radius: 9px;
    border: 1px solid var(--hu-border-strong);
    background: #1b1b1b;
    padding: 0.45rem 0.6rem;
    color: var(--hu-text-main);
}

.hu-field input[disabled] {
    opacity: 0.9;
}

.hu-login__note {
    margin: 0.45rem 0 0;
    font-size: 0.76rem;
    color: var(--hu-text-muted);
}

/* ---------- Page / Feed header ---------- */

.hu-page-header,
.hu-feed-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 48px;
    background: var(--hu-surface);
    border-radius: var(--hu-radius-lg);
    border: 1px solid var(--hu-border-title);
    padding: 0 1rem;
}

.hu-page-header {
    margin-bottom: 1.1rem;
}

.hu-feed-header {
    margin-bottom: 0;
}

.hu-feed-header__title {
    margin: 0;
    font-family: var(--hu-font-heading);
    font-size: 1.1rem;
}

.hu-feed-header__sort {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-size: 0.8rem;
}

.hu-feed-sort__link {
    color: var(--hu-text-muted);
    text-decoration: none;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.hu-feed-sort__link:hover,
.hu-feed-sort__link.is-active {
    color: var(--hu-accent-main);
}

/* ---------- Feed layout ---------- */

.hu-feed {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr) 320px;
    gap: 1.25rem;
    align-items: flex-start;
}

.hu-feed__sidebar {
    align-self: flex-start;
    position: sticky;
    top: calc(var(--hu-nav-height) + 1rem);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.hu-feed__stream {
    max-width: none;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.hu-feed__ads {
    width: 320px;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.hu-feed-adcard {
    padding: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hu-feed-adcard__image {
    width: 300px;
    height: 250px;
    display: block;
}

/* Feed cards */

.hu-feed-card {
    display: flex;
    flex-direction: row;
    padding: 0.8rem;
    position: relative;
}

.hu-feed-card--compact {
    height: 156px;
    padding: 0;
}

/* Image strip on left */

.hu-feed-card__media {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 140px;
    display: flex;
    align-items: stretch;
    justify-content: flex-start;
    margin-right: 0;
    border-radius: var(--hu-radius-lg) 0 0 var(--hu-radius-lg);
    overflow: hidden;
    z-index: 1;
}

.hu-feed-card__image {
    width: 100%;
    height: 100%;
    border-radius: 0;
    object-fit: cover;
    display: block;
}

/* Feed card content */

.hu-feed-card__content {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
    margin-left: 140px;
    padding: 1rem 1rem 0.85rem 1rem;
}

.hu-feed-card__header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
}

.hu-feed-card__title {
    margin: 0;
    font-family: var(--hu-font-heading);
    font-size: 1rem;
}

.hu-feed-card__body {
    margin: 0 0 0.45rem;
    font-size: 0.86rem;
    color: var(--hu-text-soft);
}

.hu-feed-card__meta {
    font-size: 0.78rem;
    color: var(--hu-text-muted);
    margin-bottom: 0.5rem;
}

.hu-feed-card__footer {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hu-feed-card__stats {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.76rem;
    color: var(--hu-text-muted);
}

.hu-feed-card__stat-icon {
    font-size: 0.8rem;
    margin-right: 0.15rem;
}

/* Feed ad card (inside stream) */

.hu-feed-card--ad {
    height: 284px;
    align-items: center;
    justify-content: center;
}

.hu-feed-ad__image {
    width: 300px;
    height: 250px;
    display: block;
}

/* Load more */

.hu-feed-more {
    margin: 0.7rem auto 0;
    padding: 0.4rem 1rem;
    border-radius: var(--hu-radius-pill);
    border: 1px dashed var(--hu-border-strong);
    background: transparent;
    color: var(--hu-text-muted);
    font-size: 0.76rem;
    cursor: pointer;
}

/* ---------- Task detail (single task page) ---------- */

.hu-task-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 1.25rem;
    align-items: flex-start;
}

.hu-task-detail {
    width: 100%;
    max-width: none;
}

.hu-task-detail .hu-card {
    display: flex;
    align-items: center;
    justify-content: center;
}

.hu-task__ads {
    width: 320px;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.hu-task-adcard {
    padding: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hu-task-adcard__image {
    width: 300px;
    height: 250px;
    display: block;
}

/* ---------- Profile / avatar combined ---------- */

.hu-profile {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 1.5rem;
}

.hu-profile__card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
}

.hu-profile__avatar {
    width: 170px;
    height: 170px;
    border-radius: 16px;
    border: none;
    object-fit: cover;
}

.hu-profile__name {
    margin: 0;
    font-family: var(--hu-font-heading);
    font-size: 1.02rem;
}

.hu-profile__role {
    margin: 0;
    font-size: 0.82rem;
    color: var(--hu-text-muted);
}

.hu-profile__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

.hu-profile__stats strong {
    color: var(--hu-accent-main);
}

.hu-profile__quote {
    font-style: italic;
    font-size: 0.84rem;
    color: var(--hu-text-soft);
}

.hu-avatar-options {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.hu-avatar-group__label {
    margin: 0 0 0.2rem;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--hu-text-muted);
}

/* ---------- Course & Task lists (compact cards) ---------- */

.hu-course-list,
.hu-task-list,
.hu-training-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1.1rem;
}

/* Base compact card: min width 349px, fixed height */

.hu-course-card,
.hu-task-card,
.hu-training-card {
    position: relative;
    display: flex;
    flex-direction: row;
    align-items: flex-start;

    flex: 1 1 349px;
    max-width: 100%;

    height: 156px;
    padding: 0;
}

.hu-course-card--create {
    cursor: pointer;
}

.hu-course-card--vip::before {
    border-color: #f7ed3d;
}

/* Title links */

.hu-course-card__title a,
.hu-task-card__title a,
.hu-training-card__title a {
    color: inherit;
    text-decoration: none;
}

.hu-course-card__title a:hover,
.hu-task-card__title a:hover,
.hu-training-card__title a:hover {
    color: inherit;
    text-decoration: underline;
}

.hu-course-card--create .hu-course-card__body {
    justify-content: center;
}

.hu-course-card--create-title {
    margin: 0 0 0.3rem;
    font-family: var(--hu-font-heading);
    font-size: 1rem;
}

.hu-course-card--create-text {
    margin: 0 0 0.7rem;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

/* Thumbnail strip */

.hu-course-card__thumb,
.hu-task-card__thumb,
.hu-training-card__thumb {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 140px;
    margin-right: 0;
    border-radius: var(--hu-radius-lg) 0 0 var(--hu-radius-lg);
    overflow: hidden;
    z-index: 1;
}

.hu-course-card__thumb img,
.hu-task-card__thumb img,
.hu-training-card__thumb img {
    width: 100%;
    height: 100%;
    border-radius: 0;
    object-fit: cover;
    display: block;
}

/* Text container */

.hu-course-card__body,
.hu-task-card__body,
.hu-training-card__body {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
    margin-left: 140px;
    padding: 1rem 1rem 0.85rem 1rem;
}

.hu-course-card__title,
.hu-task-card__title,
.hu-training-card__title {
    margin: -3px 0 0.2rem;
    font-family: var(--hu-font-heading);
    font-size: 1rem;
    line-height: 1;
}

.hu-course-card__line,
.hu-task-card__line,
.hu-training-card__line {
    margin: 0 0 0.1rem;
    font-size: 0.75rem;
}

/* Labels inside course/task/training cards */
.hu-course-card__label,
.hu-task-card__label,
.hu-training-card__label {
    color: #838383;
    margin-right: 0.25rem;
}

/* Values inside course/task/training cards */
.hu-course-card__value,
.hu-task-card__value,
.hu-training-card__value {
    color: #ffffff;
}

.hu-course-card__stats,
.hu-task-card__stats,
.hu-training-card__stats {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--hu-text-muted);
}

.hu-course-card__stat,
.hu-task-card__stat,
.hu-training-card__stat {
    display: inline-flex;
    align-items: center;
}

.hu-course-card__stat-icon,
.hu-task-card__stat-icon,
.hu-training-card__stat-icon {
    font-size: 0.8rem;
    margin-right: 0.15rem;
}

/* Course status */

.hu-course-card__status {
    margin: 0.3rem 0 0;
    font-size: 0.75rem;
}

.hu-course-card__status--in-progress {
    color: #e73dcd;
}

.hu-course-card__status--not-started {
    color: #9f9f9f;
}

.hu-course-card__status--completed {
    color: #4fd8c3;
}

.hu-course-card__title-link {
    color: inherit;
    text-decoration: none;
}

.hu-course-card__title-link:hover {
    text-decoration: underline;
}

.hu-course-card__thumb-link {
    display: inline-block;
}

.hu-task-card__title-link,
.hu-training-card__title-link {
    color: inherit;
    text-decoration: none;
}

.hu-task-card__title-link:hover,
.hu-training-card__title-link:hover {
    text-decoration: underline;
}

/* Stacked course info block inside cards (also reused on course page) */
.hu-course-meta-block {
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

.hu-course-meta-block .hu-course-card__line {
    margin: 0 0 0.2rem;
}

.hu-course-meta-block .hu-course-card__stats {
    margin-top: 0.35rem;
}

.hu-course-meta-line { }

.hu-course-meta-line--level {
    color: var(--hu-text-main);
    font-weight: 500;
}

.hu-course-meta-actions {
    margin-top: 0.2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.hu-course-start-form {
    display: inline-flex;
}


/* Column behavior for course/task/training cards */

/* 4 columns */
@media (min-width: 1489px) {
    .hu-course-card,
    .hu-task-card,
    .hu-training-card {
        max-width: calc((100% - 3 * 1.1rem) / 4);
    }
}

/* 3 columns */
@media (min-width: 1122px) and (max-width: 1488px) {
    .hu-course-card,
    .hu-task-card,
    .hu-training-card {
        max-width: calc((100% - 2 * 1.1rem) / 3);
    }
}

/* 2 columns */
@media (min-width: 756px) and (max-width: 1121px) {
    .hu-course-card,
    .hu-task-card,
    .hu-training-card {
        max-width: calc((100% - 1.1rem) / 2);
    }
}

/* 1 column */
@media (max-width: 755px) {
    .hu-course-card,
    .hu-task-card,
    .hu-training-card {
        flex: 1 0 100%;
        max-width: 100%;
    }
}

/* ---------- Achievements ---------- */

.hu-achievements {
    margin-top: 0.4rem;
}

.hu-achievement {
    display: flex;
    gap: 0.8rem;
    align-items: flex-start;
}

.hu-achievement__icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    border: 1px solid var(--hu-border-strong);
    object-fit: cover;
    flex-shrink: 0;
}

.hu-achievement__body {
    flex: 1;
}

.hu-achievement__status {
    margin: 0 0 0.18rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--hu-text-muted);
}

.hu-achievement__status--unlocked {
    color: var(--hu-accent-secondary);
}

.hu-achievement--locked {
    opacity: 0.45;
    filter: grayscale(1);
}

/* Mobile-only items in the hamburger menu */
.hu-nav__item--mobile-only {
    display: none;
}

/* VIP link styling inside mobile menu */
.hu-nav__link--vip {
    justify-content: flex-start;
    width: 100%;
}

/* ---------- Overlay behind mobile nav ---------- */

.hu-nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease-out;
    z-index: 200; /* above network/header/content, below drawer */
}

.hu-nav-overlay.is-active {
    opacity: 1;
    pointer-events: auto;
}

/* ---------- Course outline overlay + drawer (mobile) ---------- */

.hu-course-outline-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease-out;
    z-index: 200; /* same layer as nav overlay */
}

.hu-course-outline-overlay.is-active {
    opacity: 1;
    pointer-events: auto;
}

.hu-course-outline-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 260px;
    max-width: 100%;
    background: #222222;
    border-left: 1px solid #373737;
    z-index: 220; /* above overlay, like nav drawer */
    transform: translateX(100%);
    transition: transform 220ms ease-out;
    display: flex;
    flex-direction: column;
    padding: 0.75rem;

    /* NEW: scroll inside the drawer, not the page */
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.hu-course-outline-drawer .hu-course-outline-card {
    height: 100%;
}

.hu-course-outline-drawer.is-open {
    transform: translateX(0);
}

/* ---------- Course layout & detail page ---------- */

/* Layout: main content + outline sidebar */
.hu-course-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px; /* main + sidebar */
    gap: 1.25rem;
    align-items: flex-start;
}

.hu-course-main {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.hu-course-sidebar {
    width: 320px;
}

/* ---------- Course header (title card) ---------- */

.hu-course-header {
    margin-bottom: 0;
    padding: 0.8rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hu-course-header__title {
    margin: 0;
    font-family: var(--hu-font-heading);
    font-size: 1.1rem;             /* match .hu-feed-header__title */
}

/* Mobile outline toggle button (icon on right) */
.hu-course-outline-toggle-btn {
    display: none; /* shown only on mobile */
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    background: #1b1b1b;
    color: var(--hu-text-main);
    cursor: pointer;
}

.hu-course-outline-toggle-btn i {
    font-size: 0.9rem;
}

/* Status pill (In progress / Completed) in the title card */
.hu-course-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.6rem;
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    font-size: 0.72rem;
    color: var(--hu-accent-secondary);
}

/* Meta row just under the title card */

.hu-course-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.75rem 1.25rem;
    margin: 0.75rem 0 0.9rem;
}

.hu-course-header__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    font-size: 0.8rem;
    color: var(--hu-text-muted);
    align-items: center;
}

.hu-course-header__rating i {
    margin-right: 0.18rem;
    color: #f7d27c;
}

.hu-course-header__rating strong {
    color: var(--hu-text-main);
    margin-right: 0.25rem;
}

.hu-course-header__completions {
    color: var(--hu-text-muted);
}

.hu-course-header__creator {
    color: var(--hu-accent-secondary);
    text-decoration: none;
}

.hu-course-header__creator:hover {
    text-decoration: underline;
}

.hu-course-header__creator--anon {
    color: var(--hu-text-muted);
}

.hu-course-header__level,
.hu-course-header__length {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Info stack: cost / reward, favorite, etc. */
.hu-course-header__side {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.9rem;
    margin-left: 0;
    text-align: left;
}

.hu-course-header__costs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    font-size: 0.78rem;
}

.hu-course-header__cost-label {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.68rem;
    color: var(--hu-text-muted);
}

.hu-course-header__cost-value {
    font-size: 0.8rem;
}

/* Favorite button */

.hu-course-favorite {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.7rem;
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    background: #1b1b1b;
    font-size: 0.75rem;
    cursor: pointer;
    color: var(--hu-text-soft);
}

.hu-course-favorite[aria-pressed="true"] {
    border-color: var(--hu-accent-main);
    color: var(--hu-accent-main);
}

.hu-course-favorite i {
    font-size: 0.85rem;
}

/* Make Start button visually prominent */
.hu-course-start-btn {
    margin-top: 0.15rem;
    padding-inline: 1.4rem;
}

/* ---------- Course main content (current section) ---------- */

.hu-course-content-card {
    padding-top: 0.9rem;
}

.hu-course-content__kicker {
    margin: 0 0 0.25rem;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--hu-text-muted);
}

.hu-course-content__title {
    margin: 0 0 0.6rem;
    font-family: var(--hu-font-heading);
    font-size: 1.05rem;
}

.hu-course-content-items {
    list-style: none;
    padding: 0;
    margin: 0.3rem 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.hu-course-content-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.hu-course-content-item__meta {
    flex: 1;
}

.hu-course-content-item__type {
    display: inline-flex;
    align-items: center;
    padding: 0.1rem 0.55rem;
    border-radius: var(--hu-radius-pill);
    border: 1px solid var(--hu-border-subtle);
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--hu-text-muted);
    margin-bottom: 0.25rem;
}

.hu-course-content-item__title {
    margin: 0 0 0.25rem;
    font-size: 0.9rem;
}

.hu-course-content-item__desc {
    margin: 0 0 0.25rem;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

.hu-course-content-item__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    font-size: 0.76rem;
    color: var(--hu-text-muted);
}

.hu-course-content-item__stats i {
    margin-right: 0.18rem;
}

.hu-course-content-item__btn {
    align-self: center;
    white-space: nowrap;
}

/* ---------- About / preview section (inside cards) ---------- */

.hu-course-preview-card {
    padding-top: 0.9rem;
}

/* Row: "About this course" (left) + Start Course button (right, preview mode) */
.hu-course-preview__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin: 0 0 0.5rem; /* small, consistent gap to content */
}

/* Left stack: heading + info stack */
.hu-course-preview__header-main {
    display: flex;
    flex-direction: column;
    gap: 0.25rem; /* tight gap between heading and Level 3 · 14 days */
}

/* Heading style: reused for About / What you'll learn / etc. */
.hu-course-preview__title {
    margin: 0;
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0;
    color: var(--hu-text-main); /* white */
}

/* Right: Start course button block */
.hu-course-preview__header-action {
    flex-shrink: 0;
}

/* Intro line ("Daily audio, reflection prompts...") */
.hu-course-preview__intro {
    margin: 0 0 0.7rem;
    font-size: 0.86rem;
    color: var(--hu-text-soft);
}

/* What you'll learn / Requirements / Tags headings */
.hu-course-preview__subheading {
    margin: 0.6rem 0 0.3rem;
    font-size: 0.95rem;        /* same size as About this course */
    text-transform: none;      /* normal case */
    letter-spacing: 0;         /* remove all-caps spacing */
    color: var(--hu-text-main);/* white */
}

.hu-course-preview__learn-list,
.hu-course-preview__requirements {
    margin-top: 0.1rem;
}

.hu-course-preview__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.1rem;
}

.hu-course-preview__completion-note {
    margin: 0.7rem 0 0;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
    font-style: italic;
}

/* ---------- Course outline sidebar ---------- */

.hu-course-outline-card {
    padding-top: 0.9rem;
}

/* Outline card header row: title + status badge */
.hu-course-outline__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.5rem;   /* no top margin -> no collapsing */
}

/* Match "About this course" heading style */
.hu-course-outline__title {
    margin: 0;
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0;
    color: var(--hu-text-main); /* white */
}

/* Badge variant in outline */
.hu-course-status-badge--outline {
    margin-top: 0;
    position: static;
}

.hu-course-outline__empty {
    margin: 0.3rem 0 0;
    font-size: 0.8rem;
    color: var(--hu-text-soft);
}

.hu-course-outline__list {
    list-style: none;
    padding: 0;
    margin: 0.3rem 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.hu-course-outline__item {
    border-radius: var(--hu-radius-md);
    border: 1px solid var(--hu-border-subtle);
    background: #1b1b1b;
    overflow: hidden;
}

.hu-course-outline__item.is-current {
    border-color: var(--hu-accent-main);
}

.hu-course-outline__item.is-locked {
    opacity: 0.85;
}

.hu-course-outline__section {
    border: none;
    margin: 0;
    padding: 0;
}

.hu-course-outline__summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.45rem 0.55rem 0.45rem 0.7rem;
    font-size: 0.8rem;
}

.hu-course-outline__summary::-webkit-details-marker {
    display: none;
}

.hu-course-outline__summary-main {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.hu-course-outline__day {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--hu-text-muted);
}

.hu-course-outline__label {
    font-size: 0.8rem;
}

.hu-course-outline__chevron i {
    font-size: 0.8rem;
    color: var(--hu-text-muted);
    transition: transform 150ms ease-out;
}

.hu-course-outline__section[open] .hu-course-outline__chevron i {
    transform: rotate(180deg);
}

.hu-course-outline__body {
    padding: 0 0.7rem 0.55rem;
    border-top: 1px solid var(--hu-border-subtle);
    background: #181818;
}

.hu-course-outline__items {
    list-style: none;
    padding: 0.4rem 0 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: 0.78rem;
}

.hu-course-outline__item-row {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
}

.hu-course-outline__item-type {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--hu-text-muted);
    min-width: 3.3rem;
}

.hu-course-outline__item-link,
.hu-course-outline__item-label {
    flex: 1;
}

.hu-course-outline__item-link {
    color: var(--hu-text-main);
    text-decoration: none;
}

.hu-course-outline__item-link:hover {
    text-decoration: underline;
}

.hu-course-outline__hint {
    margin: 0.45rem 0 0;
    font-size: 0.72rem;
    color: var(--hu-text-muted);
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
    .hu-container {
        width: min(1450px, 100% - 2.5rem);
        margin: 0 auto;
    }

    /* Left-side drawer for nav on mobile */
    .hu-menubar {
        position: fixed;
        top: 0;                     /* full viewport */
        left: 0;
        height: 100vh;              /* fill full height */
        width: 220px;               /* drawer width so text does not clip */
        background: #222222;
        border-right: 1px solid #373737;
        z-index: 220;               /* above overlay (200) and header (20) */
        transform: translateX(-100%);
        transition: transform 220ms ease-out;
        pointer-events: none;
    }

    .hu-menubar.is-open {
        transform: translateX(0);
        pointer-events: auto;
    }

    .hu-menubar__inner {
        height: 100%;
        display: flex;
        align-items: stretch;
    }

    .hu-nav {
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    .hu-menubar .hu-nav__list {
        flex: 1;
        flex-direction: column;
        align-items: flex-start;
        padding: 30px 1rem 1.5rem 1rem; /* 30px from top */
        gap: 0.75rem;
    }

    /* Slightly tighter header spacing, but still one row */
    .hu-header__inner {
        gap: 0.5rem;
    }

    /* Control flex order on mobile:
       1: logo, 2: search, 3: hamburger, 4: (hidden) right group */
    .hu-brand {
        order: 1;
        flex: 0 0 auto;
    }

    .hu-header-search {
        order: 2;
        flex: 1 1 auto;
        max-width: 420px;
        min-width: 0;
        margin: 0 0.25rem;
        margin-left: 1.75rem;
    }

    .hu-nav-toggle {
        order: 3;
        display: inline-flex;
        margin-left: auto;
    }

    .hu-header__right {
        order: 4;
        display: none;
    }

    /* Mobile-only items now visible in the drawer */
    .hu-nav__item--mobile-only {
        display: block;
    }

    /* VIP entry image inside list behaves nicely */
    .hu-nav__link--vip .hu-header__vip-image {
        height: 32px;
        width: auto;
        display: block;
    }

    .hu-hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .hu-hero__panel {
        justify-content: flex-start;
    }

    .hu-feed {
        grid-template-columns: minmax(0, 1fr);
    }

    .hu-feed__sidebar {
        position: static;
        order: -1;
    }

    .hu-feed__ads {
        display: none;
    }

    .hu-section--top-students {
        display: none;
    }

    .hu-profile {
        grid-template-columns: minmax(0, 1fr);
    }

    .hu-footer__inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .hu-course-card,
    .hu-task-card,
    .hu-training-card {
        width: 100%;
    }

    .hu-task-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .hu-task__ads {
        display: none;
    }

    .hu-course-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    /* Hide desktop sidebar on mobile – outline moves into drawer */
    .hu-course-sidebar--desktop {
        display: none;
    }

    .hu-course-header {
        flex-direction: row;
        align-items: center;
        gap: 0.6rem;
    }

    .hu-course-header__side {
        align-items: flex-start;
        margin-left: 0;
    }

    /* Show the outline toggle button on mobile */
    .hu-course-outline-toggle-btn {
        display: inline-flex;
    }
}

@media (max-width: 600px) {
    .hu-main {
        padding-top: 1.4rem;
    }

    .hu-container {
        width: min(1450px, 100% - 1.2rem);
        margin: 0 auto;
    }

    .hu-hero__title {
        font-size: 1.7rem;
    }

    /* Slightly smaller logo so everything fits */
    .hu-brand__image {
        height: 34px;
        max-width: 150px;
    }

    /* Keep header compact but still vertically centered */
    .hu-header__inner {
        height: var(--hu-nav-height);
        gap: 0.4rem;
    }

    /* Narrower search on very small phones, still between logo and hamburger */
    .hu-header-search {
        flex: 0 1 50%;   /* let it take about half the row */
        max-width: 50%;  /* cap width so it doesn’t stretch too far */
        margin: 0;
        margin-left: 0.5rem;
    }

    .hu-header-search__input {
        padding: 0 0.5rem;
        font-size: 1rem;  /* keep at least 16px to avoid zoom */
    }

    .hu-header-search__button {
        min-width: 40px;
        padding: 0 0.5rem;
    }
}
