.learning-dashboard {
    --learning-blue: #155eef;
    --learning-blue-deep: #0b3ea8;
    --learning-cyan: #0e7490;
    --learning-green: #16803c;
    --learning-orange: #d97706;
    --learning-violet: #6d5bd0;
    --learning-ink: #102a43;
    --learning-muted: #667085;
    --learning-line: #e5eaf2;
    --learning-bg: #f6f9fd;
    max-width: 1240px;
    margin: 0 auto;
    padding: 24px 18px 56px;
    color: var(--learning-ink);
}

.learning-dashboard * {
    box-sizing: border-box;
}

.learning-dashboard__hero {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(250px, .55fr);
    gap: 26px;
    align-items: stretch;
    padding: 34px;
    border: 1px solid #dbe7fb;
    border-radius: 28px;
    background:
        radial-gradient(circle at 92% 8%, rgba(58, 151, 255, .18), transparent 28%),
        linear-gradient(135deg, #f8fbff 0%, #eef5ff 60%, #f4fbff 100%);
    box-shadow: 0 18px 48px rgba(27, 78, 146, .08);
    overflow: hidden;
}

.learning-dashboard__hero-copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.learning-dashboard__back,
.learning-dashboard__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.learning-dashboard__back {
    margin-bottom: 18px;
    color: #486581;
    font-size: .9rem;
    font-weight: 700;
    text-decoration: none;
}

.learning-dashboard__back:hover {
    color: var(--learning-blue);
}

.learning-dashboard__eyebrow,
.learning-kicker {
    color: var(--learning-blue);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.learning-dashboard__hero h1 {
    max-width: 760px;
    margin: 10px 0 12px;
    font-size: clamp(2rem, 4vw, 3.35rem);
    line-height: 1.02;
    letter-spacing: -.045em;
    color: #0b2447;
}

.learning-dashboard__hero p {
    max-width: 760px;
    margin: 0;
    color: #4d6278;
    font-size: 1.02rem;
    line-height: 1.7;
}

.learning-dashboard__hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.learning-btn {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 17px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-weight: 800;
    text-decoration: none;
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.learning-btn:hover {
    transform: translateY(-1px);
}

.learning-btn--primary {
    background: linear-gradient(135deg, var(--learning-blue), #2979f2);
    color: #fff;
    box-shadow: 0 10px 24px rgba(21, 94, 239, .2);
}

.learning-btn--primary:hover {
    color: #fff;
    box-shadow: 0 14px 28px rgba(21, 94, 239, .24);
}

.learning-btn--ghost,
.learning-btn--secondary {
    border-color: #cfdcf1;
    background: #fff;
    color: #24476b;
}

.learning-btn--ghost:hover,
.learning-btn--secondary:hover {
    color: var(--learning-blue);
    border-color: #a9c4f0;
}

.learning-btn--full {
    width: 100%;
}

.learning-dashboard__signal {
    display: flex;
    min-height: 210px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, .85);
    border-radius: 24px;
    background: rgba(255, 255, 255, .84);
    text-align: center;
    box-shadow: inset 0 1px 0 #fff, 0 16px 32px rgba(31, 78, 121, .08);
}

.learning-dashboard__signal-icon {
    display: grid;
    width: 54px;
    height: 54px;
    margin-bottom: 10px;
    place-items: center;
    border-radius: 18px;
    background: #fff2cc;
    color: #b76e00;
    font-size: 1.45rem;
}

.learning-dashboard__signal > div {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.learning-dashboard__signal strong {
    color: #0b2447;
    font-size: 3rem;
    line-height: 1;
}

.learning-dashboard__signal span {
    color: #425b76;
    font-weight: 800;
}

.learning-dashboard__signal small {
    margin-top: 9px;
    color: #74859a;
    line-height: 1.45;
}

.learning-login-banner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 16px;
    align-items: center;
    margin-top: 18px;
    padding: 18px 20px;
    border: 1px solid #cfe0ff;
    border-radius: 18px;
    background: #f7fbff;
}

.learning-login-banner__icon {
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    border-radius: 14px;
    background: #e8f1ff;
    color: var(--learning-blue);
    font-size: 1.25rem;
}

.learning-login-banner strong {
    color: #183b63;
}

.learning-login-banner p {
    margin: 3px 0 0;
    color: #62748a;
    font-size: .92rem;
}

.learning-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.learning-metric {
    display: flex;
    gap: 14px;
    align-items: center;
    min-height: 126px;
    padding: 18px;
    border: 1px solid var(--learning-line);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(37, 72, 110, .055);
}

.learning-metric__icon,
.learning-history-item__icon,
.learning-continue-card__icon {
    display: grid;
    flex: 0 0 auto;
    place-items: center;
}

.learning-metric__icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    font-size: 1.25rem;
}

.learning-metric--blue .learning-metric__icon { background: #eaf2ff; color: var(--learning-blue); }
.learning-metric--green .learning-metric__icon { background: #eaf8ee; color: var(--learning-green); }
.learning-metric--cyan .learning-metric__icon { background: #e6f7fb; color: var(--learning-cyan); }
.learning-metric--orange .learning-metric__icon { background: #fff4df; color: var(--learning-orange); }

.learning-metric > div {
    min-width: 0;
}

.learning-metric small,
.learning-metric span {
    display: block;
}

.learning-metric small {
    color: #75869a;
    font-size: .78rem;
    font-weight: 700;
}

.learning-metric strong {
    display: block;
    margin: 3px 0;
    color: #0b2447;
    font-size: 1.7rem;
    line-height: 1.05;
}

.learning-metric span {
    color: #5e7187;
    font-size: .78rem;
    line-height: 1.4;
}

.learning-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(330px, .65fr);
    gap: 18px;
    margin-top: 18px;
}

.learning-grid--middle,
.learning-grid--bottom {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.learning-panel {
    min-width: 0;
    padding: 22px;
    border: 1px solid var(--learning-line);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(37, 72, 110, .055);
}

.learning-panel--continue {
    margin-top: 18px;
}

.learning-panel__heading {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 18px;
}

.learning-panel__heading h2 {
    margin: 4px 0 0;
    color: #102f53;
    font-size: 1.2rem;
    letter-spacing: -.018em;
}

.learning-panel__heading > a {
    flex: 0 0 auto;
    color: var(--learning-blue);
    font-size: .84rem;
    font-weight: 800;
    text-decoration: none;
}

.learning-panel__badge {
    padding: 7px 10px;
    border-radius: 999px;
    background: #eff5ff;
    color: #4b6380;
    font-size: .8rem;
}

.learning-panel__badge strong {
    color: var(--learning-blue);
}

.learning-week-chart {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 10px;
    min-height: 190px;
    align-items: end;
}

.learning-week-day {
    display: grid;
    grid-template-rows: 132px auto auto;
    gap: 4px;
    justify-items: center;
    min-width: 0;
}

.learning-week-day__track {
    display: flex;
    width: min(34px, 72%);
    height: 132px;
    align-items: flex-end;
    border-radius: 999px;
    background: #eef3f9;
    overflow: hidden;
}

.learning-week-day__track > span {
    width: 100%;
    height: max(6px, calc(var(--activity-height, 0) * 1%));
    border-radius: 999px;
    background: linear-gradient(180deg, #4a9cff, #155eef);
    transition: height .25s ease;
}

.learning-week-day strong {
    color: #294761;
    font-size: .82rem;
}

.learning-week-day small {
    color: #8290a2;
    font-size: .72rem;
    text-transform: uppercase;
}

.learning-panel__footnote,
.learning-listening-note {
    color: #738399;
    font-size: .8rem;
    line-height: 1.55;
}

.learning-panel__footnote {
    margin: 14px 0 0;
}

.learning-mastery {
    display: grid;
    gap: 16px;
}

.learning-mastery__level {
    display: flex;
    gap: 14px;
    align-items: center;
}

.learning-mastery__level > span {
    display: grid;
    width: 66px;
    height: 66px;
    place-items: center;
    border-radius: 19px;
    background: linear-gradient(135deg, #155eef, #46a0ff);
    color: #fff;
    font-size: 1.3rem;
    font-weight: 900;
    box-shadow: 0 12px 24px rgba(21, 94, 239, .2);
}

.learning-mastery__level strong,
.learning-mastery__level small {
    display: block;
}

.learning-mastery__level strong {
    color: #15395e;
}

.learning-mastery__level small {
    margin-top: 3px;
    color: #7a8b9e;
}

.learning-mastery__score {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.learning-mastery__score > span {
    padding: 12px;
    border-radius: 15px;
    background: #f6f9fc;
}

.learning-mastery__score strong,
.learning-mastery__score small {
    display: block;
}

.learning-mastery__score strong {
    color: #173b63;
    font-size: 1.2rem;
}

.learning-mastery__score small {
    margin-top: 2px;
    color: #79899b;
    font-size: .76rem;
}

.learning-progress {
    width: 100%;
    height: 10px;
    border: 0;
    border-radius: 999px;
    overflow: hidden;
    appearance: none;
}

.learning-progress::-webkit-progress-bar { background: #edf2f7; }
.learning-progress::-webkit-progress-value { background: linear-gradient(90deg, #155eef, #48a1ff); border-radius: 999px; }
.learning-progress::-moz-progress-bar { background: linear-gradient(90deg, #155eef, #48a1ff); border-radius: 999px; }

.learning-mastery p {
    margin: 0;
    color: #63758a;
    font-size: .88rem;
    line-height: 1.55;
}

.learning-continue-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.learning-continue-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    min-width: 0;
    padding: 16px;
    border: 1px solid #e3eaf2;
    border-radius: 18px;
    color: inherit;
    text-decoration: none;
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.learning-continue-card:hover {
    transform: translateY(-2px);
    border-color: #c6d8f1;
    box-shadow: 0 12px 24px rgba(32, 78, 124, .08);
}

.learning-continue-card__icon {
    width: 42px;
    height: 42px;
    border-radius: 13px;
}

.learning-continue-card--blue .learning-continue-card__icon { background: #eaf2ff; color: var(--learning-blue); }
.learning-continue-card--orange .learning-continue-card__icon { background: #fff4df; color: var(--learning-orange); }
.learning-continue-card--cyan .learning-continue-card__icon { background: #e7f7fb; color: var(--learning-cyan); }
.learning-continue-card--violet .learning-continue-card__icon { background: #f0edff; color: var(--learning-violet); }

.learning-continue-card > div {
    min-width: 0;
}

.learning-continue-card small,
.learning-continue-card strong,
.learning-continue-card span {
    display: block;
}

.learning-continue-card small {
    color: #7e8d9e;
    font-size: .7rem;
    font-weight: 800;
    text-transform: uppercase;
}

.learning-continue-card strong {
    margin-top: 2px;
    overflow: hidden;
    color: #173b63;
    font-size: .92rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.learning-continue-card span {
    margin-top: 3px;
    overflow: hidden;
    color: #74869a;
    font-size: .76rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.learning-weak-list,
.learning-history-list,
.learning-quiz-history {
    display: grid;
    gap: 10px;
}

.learning-weak-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 13px 0;
    border-bottom: 1px solid #edf1f5;
}

.learning-weak-item:last-child {
    border-bottom: 0;
}

.learning-weak-item__rank {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 10px;
    background: #fff3df;
    color: #b76800;
    font-size: .78rem;
    font-weight: 900;
}

.learning-weak-item strong,
.learning-weak-item small {
    display: block;
}

.learning-weak-item strong {
    color: #173b63;
    font-size: .9rem;
}

.learning-weak-item small {
    margin-top: 3px;
    color: #8090a1;
    font-size: .76rem;
}

.learning-weak-item__actions {
    display: flex;
    gap: 7px;
}

.learning-weak-item__actions a {
    padding: 6px 9px;
    border: 1px solid #dbe4ef;
    border-radius: 9px;
    color: #4e6680;
    font-size: .75rem;
    font-weight: 800;
    text-decoration: none;
}

.learning-weak-item__actions a.is-primary {
    border-color: #c9dcff;
    background: #edf4ff;
    color: var(--learning-blue);
}

.learning-quiz-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 14px;
}

.learning-quiz-stats > span {
    padding: 11px 8px;
    border-radius: 14px;
    background: #f7f9fc;
    text-align: center;
}

.learning-quiz-stats strong,
.learning-quiz-stats small {
    display: block;
}

.learning-quiz-stats strong {
    color: #173b63;
    font-size: 1.05rem;
}

.learning-quiz-stats small {
    margin-top: 3px;
    color: #7a899b;
    font-size: .68rem;
}

.learning-quiz-record {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 11px 0;
    border-bottom: 1px solid #edf1f5;
    color: inherit;
    text-decoration: none;
}

.learning-quiz-record:last-child {
    border-bottom: 0;
}

.learning-quiz-record strong,
.learning-quiz-record small {
    display: block;
}

.learning-quiz-record strong {
    color: #183b63;
    font-size: .86rem;
}

.learning-quiz-record small {
    margin-top: 3px;
    color: #7e8d9d;
    font-size: .74rem;
}

.learning-quiz-record > span {
    min-width: 50px;
    padding: 6px 8px;
    border-radius: 9px;
    background: #eef5ff;
    color: var(--learning-blue);
    font-size: .78rem;
    font-weight: 900;
    text-align: center;
}

.learning-history-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 11px 0;
    border-bottom: 1px solid #edf1f5;
    color: inherit;
    text-decoration: none;
}

.learning-history-item:last-child {
    border-bottom: 0;
}

.learning-history-item__icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
}

.learning-history-item--blue .learning-history-item__icon { background: #eaf2ff; color: var(--learning-blue); }
.learning-history-item--green .learning-history-item__icon { background: #eaf8ee; color: var(--learning-green); }
.learning-history-item--orange .learning-history-item__icon { background: #fff4df; color: var(--learning-orange); }

.learning-history-item strong,
.learning-history-item small {
    display: block;
}

.learning-history-item strong {
    color: #183b63;
    font-size: .88rem;
}

.learning-history-item small {
    margin-top: 3px;
    color: #7a8b9d;
    font-size: .75rem;
}

.learning-history-item__score {
    min-width: 48px;
    color: var(--learning-blue);
    font-size: .86rem;
    font-weight: 900;
    text-align: right;
}

.learning-listening-summary {
    display: flex;
    gap: 15px;
    align-items: center;
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(135deg, #eff9ff, #f6fbff);
}

.learning-listening-summary__icon {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 17px;
    background: #dff5ff;
    color: var(--learning-cyan);
    font-size: 1.45rem;
}

.learning-listening-summary strong,
.learning-listening-summary span {
    display: block;
}

.learning-listening-summary strong {
    color: #163b60;
}

.learning-listening-summary span {
    margin-top: 3px;
    color: #718399;
    font-size: .82rem;
}

.learning-listening-note {
    display: flex;
    gap: 8px;
    margin: 14px 0;
}

.learning-listening-note i {
    flex: 0 0 auto;
    margin-top: 2px;
    color: var(--learning-cyan);
}

.learning-empty {
    display: grid;
    justify-items: center;
    padding: 26px 16px;
    border: 1px dashed #d8e2ef;
    border-radius: 18px;
    background: #fafcff;
    text-align: center;
}

.learning-empty--compact {
    padding: 18px 12px;
}

.learning-empty > i {
    margin-bottom: 7px;
    color: #7d96b1;
    font-size: 1.35rem;
}

.learning-empty strong {
    color: #36536f;
}

.learning-empty p {
    max-width: 440px;
    margin: 5px 0 9px;
    color: #7b8b9e;
    font-size: .8rem;
    line-height: 1.5;
}

.learning-empty a {
    color: var(--learning-blue);
    font-size: .8rem;
    font-weight: 800;
    text-decoration: none;
}

@media (max-width: 1050px) {
    .learning-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .learning-continue-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .learning-dashboard {
        padding: 18px 12px 42px;
    }

    .learning-dashboard__hero,
    .learning-grid,
    .learning-grid--middle,
    .learning-grid--bottom {
        grid-template-columns: 1fr;
    }

    .learning-dashboard__hero {
        padding: 24px 20px;
    }

    .learning-dashboard__signal {
        min-height: 160px;
    }
}

@media (max-width: 620px) {
    .learning-metrics,
    .learning-continue-grid {
        grid-template-columns: 1fr;
    }

    .learning-login-banner {
        grid-template-columns: auto 1fr;
    }

    .learning-login-banner .learning-btn {
        grid-column: 1 / -1;
        width: 100%;
    }

    .learning-panel {
        padding: 18px 15px;
        border-radius: 18px;
    }

    .learning-panel__heading {
        align-items: flex-start;
    }

    .learning-panel__heading > a {
        font-size: .76rem;
    }

    .learning-week-chart {
        gap: 5px;
    }

    .learning-week-day {
        grid-template-rows: 110px auto auto;
    }

    .learning-week-day__track {
        height: 110px;
    }

    .learning-quiz-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .learning-weak-item {
        grid-template-columns: auto 1fr;
    }

    .learning-weak-item__actions {
        grid-column: 2;
        justify-content: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .learning-btn,
    .learning-continue-card,
    .learning-week-day__track > span {
        transition: none;
    }
}
