/* V10.4.0 — Pomodoro, retenção e calendário refinados */
.dashboard-panel-title {
    font-size: 1.28rem !important;
    line-height: 1.1 !important;
    font-weight: 800;
    letter-spacing: -0.01em;
    margin: 0 0 12px !important;
}


.retention-diagnostic-panel {
    grid-template-columns: minmax(240px, .95fr) minmax(360px, 1.25fr) minmax(420px, 1.6fr);
    grid-template-areas:
        "head metrics critical"
        "head phase risk";
    gap: 10px;
    align-items: stretch;
}
.retention-diagnostic-head {
    display: grid;
    grid-template-columns: 1fr;
    align-content: space-between;
    justify-items: start;
    padding: 2px 0;
}
.retention-diagnostic-head h3 {
    font-size: 1.2rem;
    line-height: 1.08;
    margin-bottom: 6px;
}
.retention-diagnostic-subtitle {
    font-size: .78rem;
    line-height: 1.4;
    margin-bottom: 6px;
    color: rgba(225,235,245,.82);
    display: block;
}
.retention-diagnostic-helper {
    margin: 0;
    font-size: .71rem;
    line-height: 1.45;
    color: rgba(176,199,218,.78);
    max-width: 28ch;
}
.retention-diagnostic-head .btn {
    margin-top: 12px;
    min-height: 38px;
    padding: 0 14px;
    font-size: .76rem;
}
.retention-metric-grid {
    gap: 8px;
    align-content: start;
}
.retention-metric {
    min-height: 72px;
    padding: 10px 11px;
}
.retention-metric span {
    font-size: .69rem;
    white-space: normal;
    line-height: 1.25;
}
.retention-metric strong { font-size: 1.15rem; }
.exam-phase-strip {
    min-height: 58px;
    padding: 10px 12px;
}
.exam-phase-strip strong { font-size: .76rem; }
.exam-phase-strip span { font-size: .72rem; white-space: normal; line-height: 1.35; }
.critical-queue-head {
    min-height: 58px;
    padding: 10px 12px;
    justify-content: space-between;
}
.critical-queue-head strong { font-size: .8rem; }
.critical-queue-head span { font-size: .7rem; white-space: normal; text-align: right; }
.retention-risk-list {
    min-height: 110px;
    max-height: 110px;
    padding-right: 2px;
}
.retention-risk-item {
    padding: 10px 11px;
    font-size: .72rem;
}

.calendar-shell-card {
    padding: 16px !important;
}
.calendar-shell-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}
.calendar-shell-title {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}
.calendar-shell-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-size: 1.3rem;
    background: linear-gradient(180deg, rgba(13,29,50,.96), rgba(11,24,43,.84));
    border: 1px solid rgba(83,227,213,.28);
    box-shadow: inset 0 0 0 1px rgba(83,227,213,.06);
}
.calendar-shell-title h3 {
    margin: 0;
    font-size: 1.28rem;
    line-height: 1.08;
}
.calendar-shell-title p {
    margin: 3px 0 0;
    font-size: .82rem;
    color: rgba(191,208,223,.8);
}
.calendar-shell-nav {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.calendar-month-selectors {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.calendar-month-selectors label {
    font-size: .76rem;
    color: rgba(205,220,235,.8);
}
.calendar-primary-actions {
    margin-bottom: 12px;
    justify-content: flex-start;
}
.month-calendar-header {
    margin-bottom: 10px;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: .73rem;
    color: rgba(170,201,230,.88);
}
.month-grid {
    gap: 10px;
}
.month-day-cell {
    height: 176px;
    padding: 10px 10px 9px;
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(13,29,50,.72), rgba(10,22,39,.84));
    border: 1px solid rgba(117,151,179,.18);
    box-shadow: inset 0 0 0 1px rgba(83,227,213,.02);
    gap: 7px;
}
.month-day-cell:hover {
    border-color: rgba(83,227,213,.42);
    background: linear-gradient(180deg, rgba(15,33,56,.82), rgba(10,24,42,.92));
}
.month-day-cell.today {
    border: 1px solid rgba(83,227,213,.74);
    box-shadow: 0 0 0 1px rgba(83,227,213,.14), inset 0 0 24px rgba(83,227,213,.06);
    background: linear-gradient(180deg, rgba(12,35,50,.92), rgba(8,25,40,.94));
}
.month-day-cell.study-active .day-num-value,
.month-day-cell.today .day-num-value { color: #6feee2; }
.month-day-cell.study-completed {
    border-color: rgba(16,185,129,.4) !important;
    background: linear-gradient(180deg, rgba(8,36,34,.65), rgba(7,26,31,.85)) !important;
}
.month-day-cell.study-overdue {
    border-color: rgba(244,114,182,.35) !important;
    background: linear-gradient(180deg, rgba(44,20,34,.65), rgba(20,17,32,.9)) !important;
}
.day-num-header {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
    align-items: flex-start;
}
.day-num-value {
    font-size: 1.15rem;
    line-height: 1;
    color: #f8fbff;
}
.day-open-btn {
    min-height: 32px !important;
    padding: 0 10px !important;
    border-radius: 10px !important;
    font-size: .72rem !important;
    border-color: rgba(117,151,179,.22) !important;
    background: rgba(11,27,45,.6) !important;
}
.day-progress-summary {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 1px;
}
.day-progress-summary span {
    font-size: .72rem;
    font-weight: 700;
    color: rgba(228,240,250,.88);
}
.day-progress-track {
    height: 4px;
    width: 100%;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(98,117,138,.2);
}
.day-progress-fill {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #22d3ee, #53e3d5);
}
.day-empty-dots {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding-top: 14px;
    opacity: .35;
}
.day-empty-dots span {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: rgba(123,154,187,.48);
}
.day-badges-scroll {
    gap: 6px;
    padding-right: 2px;
}
.day-badges-scroll.is-empty {
    justify-content: flex-end;
}
.clean-subject-badge,
.clean-subject-more {
    min-height: 28px;
    border-radius: 8px;
    font-size: .72rem;
    padding: 4px 8px;
}
.clean-subject-badge {
    background: rgba(29,78,216,.12);
    border-color: rgba(76,132,255,.45);
    color: #bcd9ff;
}
.clean-subject-badge.done {
    text-decoration: none;
    background: rgba(16,185,129,.18);
    border-color: rgba(16,185,129,.55);
    color: #94f3cc;
}
.clean-subject-badge.rev {
    background: rgba(168,85,247,.16);
    border-color: rgba(192,132,252,.48);
    color: #e1c7ff;
}
.clean-subject-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    font-weight: 700;
    color: rgba(210,225,238,.88);
    border: 1px dashed rgba(117,151,179,.34);
    background: rgba(255,255,255,.03);
}
.calendar-footer-bar {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(117,151,179,.14);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.calendar-footer-legend {
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: wrap;
}
.calendar-legend-item {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: .72rem;
    color: rgba(197,214,229,.88);
}
.calendar-legend-item::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(117,151,179,.4);
}
.calendar-legend-item.selected::before { background: #53e3d5; }
.calendar-legend-item.progress::before { background: linear-gradient(90deg, #22d3ee, #53e3d5); }
.calendar-legend-item.activity::before { background: #4c84ff; }
.calendar-legend-item.idle::before { background: rgba(117,151,179,.38); }
.calendar-footer-summary {
    display: flex;
    gap: 10px;
    align-items: stretch;
    flex-wrap: wrap;
}
.calendar-footer-summary-item {
    min-width: 110px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255,255,255,.025);
    border: 1px solid rgba(117,151,179,.15);
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.calendar-footer-summary-item strong {
    font-size: 1.02rem;
    color: #f8fbff;
}
.calendar-footer-summary-item span {
    font-size: .7rem;
    color: rgba(186,206,224,.78);
}

@media (max-width: 900px) {
    .dashboard-panel-title { font-size: 1.16rem !important; }
    .retention-diagnostic-panel {
        grid-template-columns: 1fr;
        grid-template-areas: "head" "metrics" "phase" "critical" "risk";
    }
    .retention-diagnostic-head { gap: 10px; }
    .retention-diagnostic-helper { max-width: none; }
    .retention-risk-list { min-height: 96px; max-height: 130px; }
    .calendar-shell-top,
    .calendar-shell-nav,
    .calendar-month-selectors { width: 100%; }
    .calendar-shell-nav { justify-content: space-between; }
    .calendar-month-selectors label { width: 100%; }
    .month-day-cell {
        height: 76px;
        padding: 6px 5px;
        border-radius: 12px;
        gap: 2px;
    }
    .day-progress-summary,
    .day-empty-dots,
    #monthCalendarGrid .clean-subject-badge,
    #monthCalendarGrid .clean-subject-more,
    #monthCalendarGrid .day-badges-scroll { display: none !important; }
    #monthCalendarGrid .month-day-mobile-meta {
        display: flex !important;
        justify-content: center;
        align-items: center;
        flex: 1;
    }
    .calendar-footer-bar { flex-direction: column; align-items: stretch; }
    .calendar-footer-summary { width: 100%; }
    .calendar-footer-summary-item { flex: 1 1 30%; min-width: 0; }
}

@media (max-width: 520px) {
    .calendar-shell-card { padding: 13px !important; }
    .calendar-shell-title h3 { font-size: 1.1rem; }
    .calendar-shell-title p { font-size: .74rem; }
    .calendar-shell-icon { width: 40px; height: 40px; border-radius: 12px; }
    .calendar-primary-actions .btn { min-height: 42px; font-size: .74rem; }
    .month-calendar-header { gap: 4px; font-size: .62rem; }
    .calendar-footer-legend { gap: 10px; }
    .calendar-legend-item { font-size: .66rem; }
    .calendar-footer-summary-item { padding: 9px 10px; }
}


/* =========================================================
   V10.5.0 — AUDITORIA MOBILE CONSOLIDADA
   Corrige ocupação do cabeçalho, dock de ação contextual e
   harmoniza espaçamentos sem alterar regras de negócio.
   ========================================================= */
@media (max-width: 900px) {
    html, body { overflow-x: hidden; }
    #app-dashboard {
        width: 100%;
        max-width: 100%;
        padding: 10px 10px calc(92px + env(safe-area-inset-bottom,0px)) !important;
    }
    header.modern-header {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        grid-template-columns: minmax(0,1fr) auto !important;
        gap: 10px !important;
        padding: 12px !important;
    }
    .header-brand {
        grid-column: 1 !important;
        width: 100%;
        min-width: 0;
        padding-bottom: 0 !important;
    }
    .mobile-tools-toggle {
        grid-column: 2 !important;
        align-self: center;
    }
    .header-control-stack {
        grid-column: 1 / -1 !important;
        width: 100% !important;
        min-width: 0 !important;
        margin: 4px 0 0 !important;
        gap: 7px !important;
    }
    .header-control-stack .concurso-selector-bar {
        width: 100% !important;
        max-width: none !important;
        box-sizing: border-box;
        margin: 0 !important;
        padding: 10px !important;
    }
    .concurso-selector-bar select { max-width: none !important; }
    .header-utility-cluster { width: 100% !important; }
    .header-account-actions {
        width: 100% !important;
        display: grid !important;
        grid-template-columns: repeat(3,minmax(0,1fr)) !important;
        gap: 6px !important;
    }
    .header-account-actions .btn {
        width: 100% !important;
        min-width: 0 !important;
        padding: 0 4px !important;
        white-space: normal !important;
        line-height: 1.05 !important;
    }
    .btn-search-header { width: 100% !important; }

    .study-overview-grid {
        width: 100%;
        gap: 8px !important;
    }
    .overview-card {
        min-width: 0;
        padding: 11px !important;
    }
    .overview-hint {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .retention-diagnostic-panel {
        width: 100%;
        min-width: 0;
        overflow: hidden;
    }
    .exam-phase-strip,
    .critical-queue-head,
    .retention-metric { min-width: 0; }
    .exam-phase-strip span,
    .critical-queue-head span {
        overflow-wrap: anywhere;
        word-break: normal;
    }

    /* A ação contextual deixa de flutuar sobre os cards e passa a integrar a navegação. */
    .mobile-bottom-nav {
        grid-template-columns: repeat(6,minmax(0,1fr)) !important;
        gap: 2px !important;
        padding: 6px !important;
        left: 10px !important;
        right: 10px !important;
        bottom: calc(8px + env(safe-area-inset-bottom,0px)) !important;
    }
    .mobile-nav-btn {
        min-width: 0 !important;
        padding: 7px 2px !important;
        font-size: .64rem !important;
        line-height: 1.05 !important;
    }
    .context-fab,
    #contextFab.mobile-context-action {
        position: static !important;
        inset: auto !important;
        transform: none !important;
        display: flex !important;
        width: 100% !important;
        min-width: 0 !important;
        height: auto !important;
        min-height: 50px !important;
        padding: 7px 2px !important;
        border-radius: 13px !important;
        box-shadow: none !important;
        background: rgba(83,227,213,.12) !important;
        color: #75eade !important;
        border: 1px solid rgba(83,227,213,.18) !important;
        font-size: .64rem !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .calendar-shell-card,
    #tab-edital .card,
    #tab-calendario .card,
    #tab-flashcards .card,
    #tab-anotacoes .card { max-width: 100%; box-sizing: border-box; }
}

@media (max-width: 430px) {
    #app-dashboard { padding-left: 8px !important; padding-right: 8px !important; }
    header.modern-header { padding: 10px !important; }
    .header-brand-copy h2 { font-size: 1rem !important; }
    .app-version-badge { font-size: .6rem !important; padding: 4px 6px !important; }
    .header-account-actions .btn { font-size: .62rem !important; }
    .mobile-nav-btn,
    #contextFab.mobile-context-action { font-size: .58rem !important; }
    .overview-card { min-height: 78px !important; padding: 10px !important; }
}


/* V10.5.2 — ajustes pontuais do calendário e cronograma diário */
.day-badges-scroll {
    display: flex !important;
    flex-direction: column !important;
    gap: 6px !important;
    overflow: hidden !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    padding-right: 0 !important;
    flex: 1 1 auto !important;
    min-height: 0 !important;
}
.day-badges-scroll::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}
.clean-subject-more {
    align-self: flex-start !important;
    margin-top: 0 !important;
}
.month-day-cell {
    overflow: hidden !important;
}

.study-session-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    flex-wrap: wrap;
}
.study-session-topline .day-topic-status-inline {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    min-width: 0;
    flex: 1 1 auto;
}
.study-session-topline .study-launch-controls-primary {
    display: flex !important;
    align-items: center;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    width: auto !important;
    flex: 0 0 auto;
}
.study-session-topline .study-launch-controls-primary .btn {
    min-width: 132px;
    white-space: nowrap !important;
}
.study-launch-controls-secondary {
    display: flex !important;
    align-items: center;
    gap: 8px !important;
    flex-wrap: wrap !important;
    width: 100% !important;
    margin-top: 4px;
}
.study-launch-controls-secondary .btn-register-question-result {
    order: 4;
}
.study-launch-controls-legal-row {
    display: flex !important;
    width: 100% !important;
    margin-top: 4px;
}
.study-launch-controls-legal-row .btn {
    width: auto !important;
}

@media (max-width: 900px) {
    .study-session-topline {
        align-items: flex-start;
        gap: 8px;
    }
    .study-session-topline .day-topic-status-inline {
        width: 100%;
        gap: 8px;
    }
    .study-session-topline .study-launch-controls-primary {
        width: 100% !important;
        justify-content: flex-start;
        gap: 6px !important;
    }
    .study-session-topline .study-launch-controls-primary .btn {
        min-width: 0;
        flex: 1 1 0;
    }
    .study-launch-controls-secondary {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
        gap: 6px !important;
    }
    .study-launch-controls-secondary .btn,
    .study-launch-controls-legal-row .btn {
        width: 100% !important;
        min-width: 0 !important;
        white-space: normal !important;
        text-align: center !important;
        justify-content: center !important;
    }
    .study-launch-controls-legal-row {
        width: 100% !important;
    }
}

@media (max-width: 560px) {
    .day-topic-status-inline label {
        font-size: .86rem;
    }
    .study-session-topline .study-launch-controls-primary {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
        width: 100% !important;
    }
    .study-session-topline .study-launch-controls-primary .btn {
        min-height: 38px !important;
        font-size: .72rem !important;
        padding: .42rem .34rem !important;
    }
}


/* V10.5.3 — ajustes estritamente pontuais solicitados */
.day-extra-counter {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    min-height: 28px;
    padding: 3px 8px;
    border-radius: 10px;
    border: 1px dashed rgba(117,151,179,.34);
    background: rgba(255,255,255,.03);
    color: rgba(210,225,238,.92);
    font-size: .72rem;
    font-weight: 800;
    line-height: 1;
    flex: 0 0 auto;
}
.day-extra-counter.is-empty {
    visibility: hidden;
}
.clean-subject-more {
    display: none !important;
}
.day-num-header {
    align-items: center !important;
}
.day-open-btn {
    display: none !important;
}

@media (min-width: 901px) {
    .study-session-topline {
        flex-wrap: nowrap !important;
        align-items: center !important;
    }
    .study-session-topline .day-topic-status-inline {
        flex: 0 1 auto !important;
        width: auto !important;
        align-items: center !important;
    }
    .study-session-topline .study-launch-controls-primary {
        flex: 0 0 auto !important;
        width: auto !important;
        margin-left: 2px !important;
    }
    .study-session-topline .study-launch-controls-primary .btn {
        min-width: 150px !important;
    }
    .study-launch-controls-secondary {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 8px !important;
    }
    .study-launch-controls-secondary .btn {
        flex: 0 0 auto !important;
        white-space: nowrap !important;
    }
    .study-launch-controls-secondary .btn-register-question-result {
        order: 4 !important;
    }
}

@media (max-width: 900px) {
    .day-extra-counter {
        min-width: 28px;
        min-height: 22px;
        padding: 2px 6px;
        font-size: .66rem;
        border-radius: 8px;
    }
}


/* V10.5.4 — somente Pomodoro e linhas de ação do modal do dia */
/* Pomodoro: título na mesma linha visual do título do painel de progresso. */
.grid-top > .pomodoro-card > .dashboard-panel-title {
    justify-content: flex-start !important;
    text-align: left !important;
    width: 100% !important;
    margin: 0 0 9px !important;
    padding: 0 !important;
    font-size: 1.28rem !important;
    line-height: 1.1 !important;
}
.grid-top > .card > .dashboard-panel-title {
    margin-top: 0 !important;
}
.pomodoro-card {
    padding: 14px !important;
    row-gap: 10px !important;
}
.pomodoro-hero {
    min-height: 205px !important;
}
.pomodoro-actions {
    align-self: center !important;
}
.timer-settings {
    align-self: center !important;
}

/* Modal do dia: estrutura solicitada, sem interferir nos demais layouts. */
.day-topic-status-inline {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    flex-wrap: wrap !important;
    width: 100% !important;
}
.study-status-checks {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex: 0 0 auto !important;
}
.study-session-action-row {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    min-width: 0 !important;
}
.study-session-action-row .study-session-minutes-label {
    flex: 0 0 auto !important;
    width: auto !important;
    margin: 0 !important;
}
.study-session-action-row .study-launch-controls-primary {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    width: auto !important;
}
.study-session-action-row .study-launch-controls-primary .btn {
    min-width: 132px !important;
    min-height: 38px !important;
    padding: .4rem .62rem !important;
    font-size: .72rem !important;
    white-space: nowrap !important;
}
.study-launch-controls-secondary {
    display: flex !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
    gap: 8px !important;
    width: 100% !important;
}
.study-launch-controls-secondary .btn {
    flex: 0 0 auto !important;
    white-space: nowrap !important;
}

@media (max-width: 900px) {
    .grid-top > .pomodoro-card > .dashboard-panel-title {
        font-size: 1.16rem !important;
    }
    .pomodoro-card {
        padding: 13px !important;
    }
    .day-topic-status-inline {
        gap: 8px !important;
    }
    .study-status-checks {
        width: 100% !important;
    }
    .study-session-action-row {
        width: 100% !important;
        gap: 5px !important;
    }
    .study-session-action-row .study-session-minutes-label {
        flex: 0 0 auto !important;
    }
    .study-session-action-row .study-launch-controls-primary {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
        flex: 1 1 auto !important;
        gap: 5px !important;
    }
    .study-session-action-row .study-launch-controls-primary .btn {
        min-width: 0 !important;
        width: 100% !important;
        padding: .34rem .25rem !important;
        font-size: .64rem !important;
    }
    .study-launch-controls-secondary {
        display: grid !important;
        grid-template-columns: auto auto auto minmax(0,1fr) !important;
        gap: 5px !important;
    }
    .study-launch-controls-secondary .btn {
        min-width: 0 !important;
        padding: .35rem .48rem !important;
        font-size: .65rem !important;
    }
    .study-launch-controls-secondary .btn-register-question-result {
        width: 100% !important;
        white-space: normal !important;
    }
}

@media (max-width: 480px) {
    .study-session-action-row {
        gap: 4px !important;
    }
    .study-session-minutes-label > span:first-child {
        font-size: .68rem !important;
    }
    .study-minutes-input {
        width: 48px !important;
        min-width: 48px !important;
    }
    .study-session-action-row .study-launch-controls-primary .btn {
        font-size: .59rem !important;
        line-height: 1.05 !important;
        padding: .3rem .18rem !important;
    }
    .study-launch-controls-secondary {
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
    }
    .study-launch-controls-secondary .btn {
        width: 100% !important;
        font-size: .64rem !important;
    }
}


/* V10.5.6 — ajuste pontual: Lei Seca na mesma linha das ações de estudo */
.study-session-action-row {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}
.study-session-action-row .study-launch-controls-primary {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
}
.study-session-action-row .study-launch-controls-primary .btn {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    box-sizing: border-box !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 .58rem !important;
    line-height: 1.05 !important;
}
.study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-theory,
.study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-questions {
    flex: 1.12 1 0 !important;
    min-width: 108px !important;
}
.study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-legal {
    flex: .76 1 0 !important;
    min-width: 78px !important;
}
.study-launch-controls-legal-row {
    display: none !important;
}

@media (max-width: 900px) {
    .study-session-action-row {
        gap: 5px !important;
        overflow: hidden !important;
    }
    .study-session-action-row .study-launch-controls-primary,
    .study-session-action-row .study-launch-controls-primary.has-legal-action {
        display: flex !important;
        grid-template-columns: none !important;
        flex-wrap: nowrap !important;
        gap: 5px !important;
        width: auto !important;
        min-width: 0 !important;
    }
    .study-session-action-row .study-launch-controls-primary .btn,
    .study-session-action-row .study-launch-controls-primary.has-legal-action .btn {
        min-width: 0 !important;
        width: auto !important;
        height: 38px !important;
        min-height: 38px !important;
        padding: 0 .32rem !important;
        font-size: .61rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    .study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-theory,
    .study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-questions {
        flex: 1.14 1 0 !important;
    }
    .study-session-action-row .study-launch-controls-primary.has-legal-action .btn-study-legal {
        flex: .72 1 0 !important;
    }
}

@media (max-width: 480px) {
    .study-session-action-row {
        gap: 4px !important;
    }
    .study-session-action-row .study-launch-controls-primary,
    .study-session-action-row .study-launch-controls-primary.has-legal-action {
        gap: 4px !important;
    }
    .study-session-action-row .study-launch-controls-primary .btn,
    .study-session-action-row .study-launch-controls-primary.has-legal-action .btn {
        height: 36px !important;
        min-height: 36px !important;
        max-height: 36px !important;
        padding: 0 .22rem !important;
        font-size: .56rem !important;
        letter-spacing: -.01em !important;
    }
}


/* V10.5.8 — ajuste exclusivo de alinhamento e respiro do Pomodoro */
.grid-top > .pomodoro-card > .dashboard-panel-title {
    padding-top: 4px !important;
    margin-bottom: 8px !important;
}
.pomodoro-daily-panel {
    margin-top: 12px !important;
    padding-top: 14px !important;
}
.pomodoro-daily-panel h4 {
    margin-bottom: 11px !important;
}
@media (max-width: 900px) {
    .grid-top > .pomodoro-card > .dashboard-panel-title {
        padding-top: 2px !important;
    }
    .pomodoro-daily-panel {
        margin-top: 10px !important;
        padding-top: 12px !important;
    }
}


/* V10.5.9 — alinhamento vertical exclusivo do título do Pomodoro */
@media (min-width: 901px) {
    .grid-top > .pomodoro-card > .dashboard-panel-title {
        padding-top: 18px !important;
        margin-bottom: 8px !important;
    }
}


/* V10.6.0 — Vídeoaula como atividade incremental */
.btn-study-video {
    background: linear-gradient(135deg, rgba(14,165,233,.92), rgba(34,211,238,.82)) !important;
    border-color: rgba(103,232,249,.55) !important;
    color: #04181f !important;
}
.study-status-checks {
    display:flex;
    align-items:center;
    gap:10px;
    flex-wrap:wrap;
}
.study-session-action-row .study-launch-controls-primary {
    min-width:0;
}
.study-session-action-row .study-launch-controls-primary .btn {
    min-width:0 !important;
    flex:1 1 0 !important;
    height:48px !important;
}
@media (max-width:900px) {
    .study-status-checks { gap:8px; }
    .study-session-action-row {
        display:flex !important;
        align-items:center !important;
        gap:7px !important;
        min-width:0 !important;
    }
    .study-session-action-row .study-session-minutes-label {
        flex:0 0 auto !important;
    }
    .study-session-action-row .study-launch-controls-primary {
        display:flex !important;
        flex:1 1 auto !important;
        width:auto !important;
        min-width:0 !important;
        gap:5px !important;
    }
    .study-session-action-row .study-launch-controls-primary .btn {
        flex:1 1 0 !important;
        min-width:0 !important;
        height:42px !important;
        padding:0 5px !important;
        font-size:.64rem !important;
        white-space:normal !important;
        line-height:1.05 !important;
    }
}
@media (max-width:520px) {
    .study-status-checks label { font-size:.78rem; }
    .study-session-action-row .study-launch-controls-primary .btn {
        font-size:.58rem !important;
        padding:0 3px !important;
    }
}


/* V10.6.1 — método de aquisição no editor Planejar; sem alterações fora deste componente */
@media (min-width: 901px) {
    .topic-plan-editor-grid { grid-template-columns: repeat(4, minmax(0,1fr)); }
}
@media (min-width: 641px) and (max-width: 900px) {
    .topic-plan-editor-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}


/* V10.6.2 — ajustes pontuais solicitados */
.header-brand-copy {
    display:flex;
    flex-direction:column;
    justify-content:center;
    gap:2px;
}
.header-brand-signature {
    display:block;
    margin-top:-2px;
    font-size:.92rem;
    line-height:1;
    color:rgba(153,234,225,.82);
    font-family:"Segoe Script","Brush Script MT",cursive;
    letter-spacing:.02em;
    font-weight:500;
}

.critical-queue-head {
    padding:10px 14px !important;
    min-height:unset !important;
    align-items:center !important;
}
.critical-queue-head strong {
    font-size:1rem !important;
}
.critical-queue-head span {
    font-size:.78rem !important;
    line-height:1.25 !important;
}
.retention-risk-list {
    display:grid !important;
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
    gap:10px !important;
    min-height:auto !important;
    max-height:none !important;
    overflow:visible !important;
    padding-right:0 !important;
    align-items:start;
}
.retention-risk-row.v965 {
    min-height:86px;
    height:100%;
    align-content:start;
}
.retention-risk-title {
    white-space:normal !important;
    line-height:1.25;
}
.retention-risk-meta,
.critical-layer-label {
    white-space:normal;
}

.pomodoro-daily-panel {
    gap:16px !important;
}
.pomodoro-studied-topics-panel {
    display:none;
    margin-top:6px;
    padding-top:12px;
    border-top:1px solid rgba(115,151,179,.16);
}
.pomodoro-studied-topics-panel h5 {
    margin:0 0 10px;
    font-size:.85rem;
    font-weight:800;
    letter-spacing:.02em;
    color:rgba(225,236,245,.92);
}
.pomodoro-studied-topics-list {
    display:grid;
    gap:8px;
}
.pomodoro-topic-entry {
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    gap:8px;
    align-items:center;
    padding:9px 10px;
    border-radius:12px;
    border:1px solid rgba(92,218,205,.24);
    background:rgba(9,25,45,.44);
}
.pomodoro-topic-badge {
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:24px;
    padding:0 9px;
    border-radius:999px;
    background:rgba(44,123,229,.16);
    border:1px solid rgba(84,190,255,.28);
    color:rgba(133,211,255,.94);
    font-size:.68rem;
    font-weight:800;
    letter-spacing:.04em;
    white-space:nowrap;
}
.pomodoro-topic-copy {
    min-width:0;
    display:flex;
    flex-direction:column;
    gap:3px;
}
.pomodoro-topic-copy strong {
    font-size:.82rem;
    line-height:1.25;
    color:rgba(237,243,249,.96);
}
.pomodoro-topic-copy span {
    font-size:.72rem;
    color:rgba(160,184,205,.86);
}
.pomodoro-topic-multi {
    color:rgba(153,234,225,.82);
    font-size:.7rem;
    font-weight:800;
    white-space:nowrap;
}
body.light-mode .header-brand-signature {
    color:rgba(31,122,116,.82);
}
body.light-mode .pomodoro-studied-topics-panel {
    border-top-color:rgba(21,58,88,.1);
}
body.light-mode .pomodoro-studied-topics-panel h5 {
    color:#16324a;
}
body.light-mode .pomodoro-topic-entry {
    background:rgba(255,255,255,.82);
    border-color:rgba(21,58,88,.12);
}
body.light-mode .pomodoro-topic-copy strong {
    color:#17324a;
}
body.light-mode .pomodoro-topic-copy span {
    color:#4e6377;
}
body.light-mode .pomodoro-topic-badge {
    background:rgba(44,123,229,.1);
    border-color:rgba(44,123,229,.2);
    color:#2563eb;
}

@media (max-width: 1180px) {
    .retention-risk-list {
        grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    }
}
@media (max-width: 900px) {
    .header-brand-signature {
        font-size:.84rem;
    }
    .retention-risk-list {
        grid-template-columns:1fr !important;
    }
    .pomodoro-topic-entry {
        grid-template-columns:1fr;
        gap:6px;
    }
    .pomodoro-topic-badge,
    .pomodoro-topic-multi {
        justify-self:start;
    }
}


/* V10.6.4 — correção isolada da marca: título integral + assinatura alinhada ao fim */
.header-brand-copy {
    height:auto !important;
    min-height:0 !important;
    width:fit-content !important;
    max-width:100% !important;
    min-width:0 !important;
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    justify-content:center !important;
    gap:2px !important;
    overflow:visible !important;
}
.header-brand-copy h2 {
    margin:0 !important;
    width:max-content !important;
    max-width:100% !important;
    height:auto !important;
    min-height:0 !important;
    line-height:1.08 !important;
    white-space:nowrap !important;
    overflow:visible !important;
    text-overflow:clip !important;
    font-size:clamp(1rem,2.05vw,1.55rem) !important;
}
.header-brand-signature {
    display:block !important;
    align-self:flex-end !important;
    width:auto !important;
    margin:1px 0 0 !important;
    padding:0 !important;
    line-height:1 !important;
    white-space:nowrap !important;
    overflow:visible !important;
    font-size:.88rem !important;
}

@media (max-width: 900px) {
    .header-brand-copy h2 {
        font-size:clamp(.88rem,3.05vw,1.14rem) !important;
    }
    .header-brand-signature {
        display:block !important;
        font-size:.78rem !important;
    }
}
@media (max-width: 640px) {
    .header-brand-copy h2 {
        font-size:clamp(.78rem,3.35vw,.98rem) !important;
    }
    .header-brand-signature {
        font-size:.72rem !important;
    }
}
@media (max-width: 430px) {
    .header-brand-copy h2 {
        font-size:clamp(.7rem,3.45vw,.86rem) !important;
    }
    .header-brand-signature {
        font-size:.66rem !important;
    }
}


/* V10.7.3 — Retenção e Diagnóstico: layout harmônico e funcional */
#retentionDiagnosticPanel.retention-dashboard-v1072 {
    position: relative !important;
    display: grid !important;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr) minmax(320px, 390px) !important;
    grid-template-areas: "intro center critical" !important;
    gap: 16px !important;
    align-items: stretch !important;
    padding: 16px !important;
    border-radius: 20px !important;
    border: 1px solid rgba(71, 85, 105, 0.58) !important;
    background: linear-gradient(180deg, rgba(5, 18, 33, 0.96) 0%, rgba(7, 22, 40, 0.92) 100%) !important;
    box-shadow: 0 18px 44px rgba(2, 8, 23, 0.28) !important;
    overflow: visible !important;
}

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-center-v1072,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-v1072 {
    min-width: 0 !important;
    height: 100% !important;
    border-radius: 18px !important;
    border: 1px solid rgba(71, 85, 105, 0.44) !important;
    background: linear-gradient(180deg, rgba(15, 31, 50, 0.72) 0%, rgba(10, 24, 40, 0.62) 100%) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.03) !important;
}

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072 {
    grid-area: intro !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    gap: 18px !important;
    padding: 18px !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072 > div {
    max-width: 31ch !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072 h3 {
    margin: 0 0 10px !important;
    font-size: clamp(1.95rem, 2.35vw, 2.5rem) !important;
    line-height: 1.06 !important;
    color: #ecf6ff !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-diagnostic-subtitle {
    margin: 0 !important;
    font-size: 0.98rem !important;
    line-height: 1.55 !important;
    color: #99adbf !important;
    max-width: 30ch !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-v1072 {
    align-self: flex-start !important;
    min-height: 48px !important;
    padding: 0 18px !important;
    border-radius: 14px !important;
    border: 1px solid rgba(34, 211, 238, 0.9) !important;
    background: rgba(8, 37, 54, 0.88) !important;
    color: #4de9f4 !important;
    font-size: 0.96rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.01em !important;
    box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.08) inset !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-v1072:hover,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-v1072:focus-visible {
    background: rgba(9, 49, 70, 0.98) !important;
    border-color: rgba(103, 232, 249, 1) !important;
    outline: none !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-icon {
    font-size: 0.9rem !important;
}

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-center-v1072 {
    grid-area: center !important;
    display: grid !important;
    grid-template-rows: auto auto !important;
    gap: 14px !important;
    align-content: start !important;
    padding: 18px !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metrics-v1072 {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 12px !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-v1072 {
    min-width: 0 !important;
    min-height: 146px !important;
    padding: 16px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
    justify-content: flex-start !important;
    border-radius: 16px !important;
    border: 1px solid rgba(71, 85, 105, 0.42) !important;
    background: linear-gradient(180deg, rgba(9, 31, 52, 0.92) 0%, rgba(7, 25, 44, 0.86) 100%) !important;
    color: #e8f1f8 !important;
    text-align: left !important;
    overflow: hidden !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-action:hover,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-action:focus-visible {
    border-color: rgba(77, 233, 244, 0.72) !important;
    transform: translateY(-1px) !important;
    outline: none !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-icon {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    border: 1px solid rgba(34, 211, 238, 0.14) !important;
    background: rgba(34, 211, 238, 0.06) !important;
    color: #35d7e8 !important;
    font-size: 1.08rem !important;
    line-height: 1 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-label {
    display: block !important;
    font-size: 0.88rem !important;
    line-height: 1.35 !important;
    color: #cbd8e3 !important;
    min-height: 2.4em !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-v1072 strong {
    margin-top: auto !important;
    font-size: clamp(1.8rem, 2.2vw, 2.2rem) !important;
    line-height: 1 !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
    color: #f5fbff !important;
}

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072 {
    min-width: 0 !important;
    min-height: 90px !important;
    display: grid !important;
    grid-template-columns: auto minmax(0, 1fr) !important;
    gap: 8px 14px !important;
    align-items: start !important;
    padding: 16px !important;
    border-radius: 16px !important;
    border: 1px solid rgba(71, 85, 105, 0.42) !important;
    background: linear-gradient(180deg, rgba(9, 31, 52, 0.9) 0%, rgba(7, 25, 44, 0.8) 100%) !important;
    overflow: hidden !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072::before {
    display: none !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-icon {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    width: 40px !important;
    height: 40px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    border: 1px solid rgba(34, 211, 238, 0.14) !important;
    background: rgba(34, 211, 238, 0.06) !important;
    color: #35d7e8 !important;
    font-size: 1rem !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072 strong {
    grid-column: 2 !important;
    margin: 0 !important;
    font-size: 1rem !important;
    line-height: 1.25 !important;
    color: #eef6fc !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072 > span:last-child {
    grid-column: 2 !important;
    margin: 0 !important;
    font-size: 0.92rem !important;
    line-height: 1.45 !important;
    color: #99adbf !important;
    text-align: left !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-v1072 {
    grid-area: critical !important;
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 18px 18px 56px !important;
    overflow: visible !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 6px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    background: transparent !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 strong {
    margin: 0 !important;
    font-size: 1.12rem !important;
    line-height: 1.2 !important;
    color: #eef6fc !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 span {
    margin: 0 !important;
    max-width: none !important;
    font-size: 0.84rem !important;
    line-height: 1.45 !important;
    color: #99adbf !important;
    text-align: left !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-list-v1072 {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    align-content: start !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071 {
    appearance: none !important;
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) auto !important;
    gap: 12px !important;
    align-items: start !important;
    min-height: 106px !important;
    width: 100% !important;
    padding: 14px !important;
    border-radius: 14px !important;
    border: 1px solid rgba(71, 85, 105, 0.42) !important;
    background: linear-gradient(180deg, rgba(9, 31, 52, 0.92) 0%, rgba(7, 25, 44, 0.86) 100%) !important;
    color: #e8f1f8 !important;
    text-align: left !important;
    cursor: pointer !important;
    overflow: hidden !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071:hover,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071:focus-visible {
    border-color: rgba(77, 233, 244, 0.72) !important;
    background: linear-gradient(180deg, rgba(11, 35, 59, 0.96) 0%, rgba(8, 27, 48, 0.9) 100%) !important;
    outline: none !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .critical-rank {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 10px !important;
    border: 1px solid rgba(71, 85, 105, 0.42) !important;
    background: rgba(15, 36, 57, 0.72) !important;
    color: #4de9f4 !important;
    font-weight: 800 !important;
    font-size: 0.75rem !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-copy {
    display: flex !important;
    flex-direction: column !important;
    gap: 5px !important;
    min-width: 0 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-title {
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    font-size: 0.98rem !important;
    line-height: 1.28 !important;
    font-weight: 750 !important;
    color: #eef5fb !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-meta,
#retentionDiagnosticPanel.retention-dashboard-v1072 .critical-layer-label {
    display: block !important;
    margin: 0 !important;
    font-size: 0.79rem !important;
    line-height: 1.35 !important;
    color: #99adbf !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-value {
    align-self: center !important;
    justify-self: end !important;
    font-size: 1.65rem !important;
    line-height: 1 !important;
    font-weight: 800 !important;
    color: #4de9f4 !important;
    white-space: nowrap !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-empty {
    min-height: 112px !important;
    padding: 16px !important;
    border-radius: 14px !important;
    border: 1px dashed rgba(71, 85, 105, 0.44) !important;
    background: rgba(7, 25, 44, 0.42) !important;
    color: #99adbf !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    font-size: 0.92rem !important;
    line-height: 1.45 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-more-button {
    position: absolute !important;
    right: 18px !important;
    bottom: 18px !important;
    width: 38px !important;
    height: 38px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    border: 1px solid rgba(71, 85, 105, 0.42) !important;
    background: rgba(8, 28, 46, 0.95) !important;
    color: #ecf4fa !important;
    font-size: 1.55rem !important;
    line-height: 1 !important;
    z-index: 2 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-more-button:hover,
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-more-button:focus-visible {
    border-color: rgba(77, 233, 244, 0.72) !important;
    color: #4de9f4 !important;
    outline: none !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-more-button[hidden] {
    display: none !important;
}

body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 {
    border-color: rgba(203, 213, 225, 1) !important;
    background: linear-gradient(180deg, rgba(248, 250, 252, 1) 0%, rgba(241, 245, 249, 1) 100%) !important;
    box-shadow: 0 16px 36px rgba(148, 163, 184, 0.16) !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-center-v1072,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-v1072,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-v1072,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071 {
    background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(248,250,252,0.98) 100%) !important;
    border-color: rgba(203, 213, 225, 0.94) !important;
    box-shadow: none !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072 h3,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-v1072 strong,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072 strong,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 strong,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-title {
    color: #172938 !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-diagnostic-subtitle,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-label,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-exam-v1072 > span:last-child,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 span,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-meta,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .critical-layer-label,
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-empty {
    color: #5b7085 !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-empty {
    background: rgba(241, 245, 249, 0.96) !important;
    border-color: rgba(203, 213, 225, 1) !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-v1072 {
    background: #effcff !important;
    color: #0f6f7c !important;
    border-color: rgba(34, 211, 238, 0.74) !important;
}
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-more-button {
    background: #ffffff !important;
    color: #17364c !important;
    border-color: rgba(203, 213, 225, 1) !important;
}

@media (max-width: 1240px) {
    #retentionDiagnosticPanel.retention-dashboard-v1072 {
        grid-template-columns: minmax(240px, 300px) minmax(0, 1fr) !important;
        grid-template-areas:
            "intro center"
            "critical critical" !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metrics-v1072 {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 860px) {
    #retentionDiagnosticPanel.retention-dashboard-v1072 {
        grid-template-columns: 1fr !important;
        grid-template-areas:
            "intro"
            "center"
            "critical" !important;
        gap: 14px !important;
        padding: 14px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072,
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-center-v1072,
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-v1072 {
        padding: 16px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-intro-v1072 {
        gap: 14px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-diagnostic-subtitle {
        max-width: none !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-study-now-v1072 {
        width: 100% !important;
        justify-content: center !important;
    }
}

@media (max-width: 640px) {
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metrics-v1072 {
        grid-template-columns: 1fr !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-metric-v1072 {
        min-height: 118px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071 {
        grid-template-columns: 34px minmax(0, 1fr) !important;
        grid-template-rows: auto auto !important;
        gap: 10px 12px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-value {
        grid-column: 2 !important;
        justify-self: start !important;
        align-self: start !important;
        font-size: 1.45rem !important;
    }
}


/* V10.7.4 — Retenção: criticidade visual, barra de retenção e legenda funcional */
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-head-v1072 {
    flex-direction:column !important;
    align-items:stretch !important;
    gap:12px !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-title-wrap {
    display:flex !important;
    flex-direction:column !important;
    gap:5px !important;
    min-width:0 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-critical-title-wrap > span {
    max-width:none !important;
    justify-self:auto !important;
    text-align:left !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-legend {
    display:flex !important;
    flex-wrap:wrap !important;
    gap:8px 12px !important;
    align-items:center !important;
    color:#92a7b9 !important;
    font-size:.74rem !important;
    line-height:1.2 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-legend > span {
    display:inline-flex !important;
    align-items:center !important;
    gap:6px !important;
    white-space:nowrap !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .risk-dot {
    display:inline-block !important;
    width:7px !important;
    height:7px !important;
    border-radius:999px !important;
    background:#64748b !important;
    box-shadow:0 0 0 3px rgba(100,116,139,.1) !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .risk-dot.high { background:#fb7185 !important; box-shadow:0 0 0 3px rgba(251,113,133,.11) !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .risk-dot.medium { background:#fbbf24 !important; box-shadow:0 0 0 3px rgba(251,191,36,.11) !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .risk-dot.low { background:#34d399 !important; box-shadow:0 0 0 3px rgba(52,211,153,.11) !important; }

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071 {
    position:relative !important;
    transition:transform .16s ease, border-color .16s ease, background .16s ease !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071::before {
    content:'' !important;
    position:absolute !important;
    left:0 !important;
    top:12px !important;
    bottom:12px !important;
    width:3px !important;
    border-radius:0 3px 3px 0 !important;
    background:#64748b !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-high::before { background:#fb7185 !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-medium::before { background:#fbbf24 !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-low::before { background:#34d399 !important; }

#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-topline {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) auto !important;
    gap:8px !important;
    align-items:start !important;
    min-width:0 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-topline .retention-risk-title {
    margin:0 !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge {
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    min-height:23px !important;
    padding:3px 8px !important;
    border-radius:999px !important;
    border:1px solid rgba(148,163,184,.22) !important;
    background:rgba(148,163,184,.08) !important;
    font-size:.66rem !important;
    line-height:1 !important;
    font-weight:850 !important;
    letter-spacing:.02em !important;
    text-transform:uppercase !important;
    white-space:nowrap !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.high {
    color:#fecdd3 !important;
    border-color:rgba(251,113,133,.28) !important;
    background:rgba(251,113,133,.10) !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.medium {
    color:#fde68a !important;
    border-color:rgba(251,191,36,.28) !important;
    background:rgba(251,191,36,.10) !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.low {
    color:#a7f3d0 !important;
    border-color:rgba(52,211,153,.28) !important;
    background:rgba(52,211,153,.10) !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-progress {
    display:block !important;
    width:100% !important;
    height:5px !important;
    margin-top:3px !important;
    border-radius:999px !important;
    background:rgba(148,163,184,.12) !important;
    overflow:hidden !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-progress > span {
    display:block !important;
    height:100% !important;
    border-radius:inherit !important;
    background:linear-gradient(90deg, #22d3ee 0%, #4de9f4 100%) !important;
}
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-high .retention-risk-progress > span { background:linear-gradient(90deg,#fb7185,#fda4af) !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-medium .retention-risk-progress > span { background:linear-gradient(90deg,#fbbf24,#fde68a) !important; }
#retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-card-v1071.risk-low .retention-risk-progress > span { background:linear-gradient(90deg,#34d399,#6ee7b7) !important; }

body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-legend { color:#64748b !important; }
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.high { color:#be123c !important; background:#fff1f2 !important; border-color:#fecdd3 !important; }
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.medium { color:#a16207 !important; background:#fffbeb !important; border-color:#fde68a !important; }
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge.low { color:#047857 !important; background:#ecfdf5 !important; border-color:#a7f3d0 !important; }
body.light-mode #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-progress { background:#e2e8f0 !important; }

@media (max-width:640px) {
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-topline {
        grid-template-columns:1fr !important;
        gap:6px !important;
    }
    #retentionDiagnosticPanel.retention-dashboard-v1072 .retention-risk-badge {
        justify-self:start !important;
    }
}

/* V10.7.7 — Retenção/Diagnóstico: centro isolado do CSS legado.
   Esta seção usa apenas classes rd-* para impedir colisões com versões anteriores. */
#retentionDiagnosticPanel.retention-dashboard-v1072 .rd-center-v1077 {
    grid-area: center !important;
    position: relative !important;
    isolation: isolate !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 16px !important;
    min-width: 0 !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 16px !important;
    margin: 0 !important;
    overflow: visible !important;
    box-sizing: border-box !important;
    border-radius: 18px !important;
    border: 1px solid rgba(71, 85, 105, .44) !important;
    background: linear-gradient(180deg, rgba(15,31,50,.72) 0%, rgba(10,24,40,.62) 100%) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.03) !important;
}

#retentionDiagnosticPanel .rd-exam-banner-v1077 {
    position: relative !important;
    inset: auto !important;
    z-index: 1 !important;
    flex: 0 0 auto !important;
    display: grid !important;
    grid-template-columns: 52px minmax(0,1fr) auto !important;
    grid-template-rows: minmax(70px, auto) !important;
    align-items: center !important;
    column-gap: 16px !important;
    width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 94px !important;
    max-height: none !important;
    padding: 12px 18px !important;
    margin: 0 !important;
    transform: none !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    border: 1px solid rgba(68,103,133,.42) !important;
    border-radius: 16px !important;
    background: linear-gradient(180deg, rgba(10,34,57,.96) 0%, rgba(7,27,47,.91) 100%) !important;
    color: #eef6fc !important;
}
#retentionDiagnosticPanel .rd-exam-icon-v1077 {
    display: grid !important;
    place-items: center !important;
    width: 52px !important;
    height: 52px !important;
    min-width: 52px !important;
    min-height: 52px !important;
    margin: 0 !important;
    border-radius: 999px !important;
    border: 1px solid rgba(34,211,238,.20) !important;
    background: rgba(34,211,238,.08) !important;
    color: #2dd4e8 !important;
    font-size: 1.25rem !important;
    line-height: 1 !important;
}
#retentionDiagnosticPanel .rd-exam-copy-v1077 {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    gap: 5px !important;
    min-width: 0 !important;
    width: auto !important;
    margin: 0 !important;
    color: inherit !important;
}
#retentionDiagnosticPanel .rd-exam-copy-v1077 > strong {
    display: block !important;
    margin: 0 !important;
    color: #f4f9fd !important;
    font-size: clamp(1rem,1.04vw,1.16rem) !important;
    line-height: 1.22 !important;
    font-weight: 800 !important;
    letter-spacing: -.01em !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel .rd-exam-copy-v1077 > span {
    display: block !important;
    margin: 0 !important;
    color: #9fb0c3 !important;
    font-size: clamp(.82rem,.82vw,.94rem) !important;
    line-height: 1.4 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
}
#retentionDiagnosticPanel .rd-exam-action-v1077 {
    appearance: none !important;
    justify-self: end !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 190px !important;
    min-height: 46px !important;
    padding: 0 18px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    border: 1px solid rgba(45,212,191,.86) !important;
    background: rgba(7,42,55,.84) !important;
    color: #45e4ee !important;
    font: inherit !important;
    font-size: .88rem !important;
    line-height: 1 !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
    cursor: pointer !important;
    box-shadow: none !important;
}
#retentionDiagnosticPanel .rd-exam-action-v1077:hover,
#retentionDiagnosticPanel .rd-exam-action-v1077:focus-visible {
    border-color: #67e8f9 !important;
    background: rgba(9,58,72,.96) !important;
    outline: none !important;
}
#retentionDiagnosticPanel .rd-exam-action-v1077:disabled {
    opacity: .5 !important;
    cursor: not-allowed !important;
}

#retentionDiagnosticPanel .rd-metrics-v1077 {
    position: relative !important;
    inset: auto !important;
    z-index: 0 !important;
    flex: 0 0 auto !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0,1fr)) !important;
    grid-auto-rows: 170px !important;
    gap: 14px !important;
    width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 170px !important;
    max-height: none !important;
    padding: 0 !important;
    margin: 0 !important;
    transform: none !important;
    overflow: visible !important;
    box-sizing: border-box !important;
}

#retentionDiagnosticPanel .rd-metric-card-v1077 {
    appearance: none !important;
    position: relative !important;
    inset: auto !important;
    display: grid !important;
    grid-template-columns: 54px minmax(0,1fr) !important;
    grid-template-rows: 54px 1fr auto 7px !important;
    column-gap: 14px !important;
    row-gap: 4px !important;
    align-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 170px !important;
    min-height: 170px !important;
    max-height: 170px !important;
    padding: 16px 16px 14px !important;
    margin: 0 !important;
    transform: none !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    border: 1px solid rgba(68,103,133,.42) !important;
    border-radius: 16px !important;
    background: linear-gradient(180deg, rgba(10,34,57,.96) 0%, rgba(7,27,47,.91) 100%) !important;
    color: #eef5fb !important;
    text-align: left !important;
}
#retentionDiagnosticPanel button.rd-metric-card-v1077 {
    font: inherit !important;
    cursor: pointer !important;
}
#retentionDiagnosticPanel button.rd-metric-card-v1077:hover,
#retentionDiagnosticPanel button.rd-metric-card-v1077:focus-visible {
    border-color: rgba(77,233,244,.70) !important;
    background: linear-gradient(180deg, rgba(11,38,63,.98) 0%, rgba(8,30,51,.94) 100%) !important;
    outline: none !important;
}
#retentionDiagnosticPanel .rd-metric-icon-v1077 {
    grid-column: 1 !important;
    grid-row: 1 !important;
    display: grid !important;
    place-items: center !important;
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
    min-height: 54px !important;
    border-radius: 999px !important;
    font-size: 1.45rem !important;
    line-height: 1 !important;
}
#retentionDiagnosticPanel .rd-metric-label-v1077 {
    grid-column: 2 !important;
    grid-row: 1 !important;
    align-self: center !important;
    display: block !important;
    min-width: 0 !important;
    margin: 0 !important;
    color: #dce8f1 !important;
    font-size: clamp(.90rem,.90vw,1.03rem) !important;
    line-height: 1.25 !important;
    font-weight: 750 !important;
    white-space: normal !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
}
#retentionDiagnosticPanel .rd-metric-card-v1077 > strong {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    align-self: end !important;
    justify-self: start !important;
    display: block !important;
    margin: 0 0 4px !important;
    color: #f8fbff !important;
    font-size: clamp(2rem,2.45vw,2.7rem) !important;
    line-height: .95 !important;
    font-weight: 850 !important;
    letter-spacing: -.025em !important;
    white-space: nowrap !important;
}
#retentionDiagnosticPanel .rd-metric-progress-v1077 {
    grid-column: 1 / -1 !important;
    grid-row: 4 !important;
    display: block !important;
    width: 100% !important;
    height: 7px !important;
    margin: 0 !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    background: rgba(148,163,184,.11) !important;
}
#retentionDiagnosticPanel .rd-metric-progress-v1077 > span {
    display: block !important;
    width: 0;
    height: 100% !important;
    border-radius: inherit !important;
    transition: width .24s ease !important;
}

#retentionDiagnosticPanel .rd-metric-retention-v1077 .rd-metric-icon-v1077 {
    color: #2dd4e8 !important;
    border: 1px solid rgba(34,211,238,.2) !important;
    background: rgba(34,211,238,.09) !important;
}
#retentionDiagnosticPanel .rd-metric-risk-v1077 .rd-metric-icon-v1077 {
    color: #fb923c !important;
    border: 1px solid rgba(251,146,60,.2) !important;
    background: rgba(251,146,60,.10) !important;
}
#retentionDiagnosticPanel .rd-metric-overdue-v1077 .rd-metric-icon-v1077 {
    color: #60a5fa !important;
    border: 1px solid rgba(96,165,250,.2) !important;
    background: rgba(96,165,250,.10) !important;
}
#retentionDiagnosticPanel .rd-metric-mastered-v1077 .rd-metric-icon-v1077 {
    color: #34d399 !important;
    border: 1px solid rgba(52,211,153,.2) !important;
    background: rgba(52,211,153,.10) !important;
}
#retentionDiagnosticPanel .rd-metric-retention-v1077 .rd-metric-progress-v1077 > span { background:#2dd4e8 !important; }
#retentionDiagnosticPanel .rd-metric-risk-v1077 .rd-metric-progress-v1077 > span { background:#fb923c !important; }
#retentionDiagnosticPanel .rd-metric-overdue-v1077 .rd-metric-progress-v1077 > span { background:#60a5fa !important; }
#retentionDiagnosticPanel .rd-metric-mastered-v1077 .rd-metric-progress-v1077 > span { background:#34d399 !important; }

body.light-mode #retentionDiagnosticPanel .rd-center-v1077,
body.light-mode #retentionDiagnosticPanel .rd-exam-banner-v1077,
body.light-mode #retentionDiagnosticPanel .rd-metric-card-v1077 {
    background: linear-gradient(180deg,#fff 0%,#f8fafc 100%) !important;
    border-color:#d6e0e8 !important;
}
body.light-mode #retentionDiagnosticPanel .rd-exam-copy-v1077 > strong,
body.light-mode #retentionDiagnosticPanel .rd-metric-label-v1077,
body.light-mode #retentionDiagnosticPanel .rd-metric-card-v1077 > strong {
    color:#172938 !important;
}
body.light-mode #retentionDiagnosticPanel .rd-exam-copy-v1077 > span { color:#5b7085 !important; }
body.light-mode #retentionDiagnosticPanel .rd-metric-progress-v1077 { background:#e7edf3 !important; }

@media (max-width: 1260px) {
    #retentionDiagnosticPanel .rd-metrics-v1077 {
        grid-template-columns: repeat(2,minmax(0,1fr)) !important;
        grid-auto-rows: 160px !important;
    }
    #retentionDiagnosticPanel .rd-metric-card-v1077 {
        height:160px !important;
        min-height:160px !important;
        max-height:160px !important;
    }
}

@media (max-width: 760px) {
    #retentionDiagnosticPanel .rd-center-v1077 { padding:14px !important; gap:12px !important; }
    #retentionDiagnosticPanel .rd-exam-banner-v1077 {
        grid-template-columns: 46px minmax(0,1fr) !important;
        grid-template-rows: auto auto !important;
        gap:10px 12px !important;
        padding:14px !important;
    }
    #retentionDiagnosticPanel .rd-exam-icon-v1077 {
        width:46px !important; height:46px !important; min-width:46px !important; min-height:46px !important;
    }
    #retentionDiagnosticPanel .rd-exam-action-v1077 {
        grid-column:1 / -1 !important;
        grid-row:2 !important;
        width:100% !important;
        min-width:0 !important;
        justify-self:stretch !important;
    }
}

@media (max-width: 560px) {
    #retentionDiagnosticPanel .rd-metrics-v1077 {
        grid-template-columns:1fr !important;
        grid-auto-rows:148px !important;
    }
    #retentionDiagnosticPanel .rd-metric-card-v1077 {
        height:148px !important;
        min-height:148px !important;
        max-height:148px !important;
    }
}


/* V10.7.8 — Retenção/Diagnóstico: tipografia minimalista dos rótulos */
#retentionDiagnosticPanel .rd-metric-label-v1077 {
    padding-right: 8px !important;
    font-size: clamp(.76rem, .72vw, .86rem) !important;
    line-height: 1.22 !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
    color: #c4d2de !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
    hyphens: none !important;
}

#retentionDiagnosticPanel .rd-metric-card-v1077 {
    grid-template-columns: 50px minmax(0,1fr) !important;
    column-gap: 12px !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
}

#retentionDiagnosticPanel .rd-metric-icon-v1077 {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
    min-height: 50px !important;
    font-size: 1.30rem !important;
}

body.light-mode #retentionDiagnosticPanel .rd-metric-label-v1077 {
    color: #526a7d !important;
}

@media (max-width: 1260px) {
    #retentionDiagnosticPanel .rd-metric-label-v1077 {
        font-size: .79rem !important;
    }
}

@media (max-width: 560px) {
    #retentionDiagnosticPanel .rd-metric-label-v1077 {
        font-size: .80rem !important;
    }
}

/* V10.7.9 — Modal de notas: área de escrita ampliada */
#modalNovaNota {
    padding: clamp(12px, 2vh, 24px) !important;
}

#modalNovaNota > .modal {
    width: min(94vw, 980px) !important;
    max-width: 980px !important;
    max-height: 95vh !important;
    padding: clamp(20px, 2vw, 28px) !important;
    gap: 14px !important;
    overflow-y: auto !important;
}

#modalNovaNota .form-group {
    flex: 0 0 auto !important;
}

#modalNovaNota #inputNotaConteudo {
    width: 100% !important;
    min-height: clamp(360px, 46vh, 620px) !important;
    height: clamp(360px, 46vh, 620px) !important;
    max-height: 62vh !important;
    padding: 16px 18px !important;
    font-size: 1rem !important;
    line-height: 1.6 !important;
    resize: vertical !important;
    overflow-y: auto !important;
}

#modalNovaNota .modal-actions {
    flex: 0 0 auto !important;
    margin-top: 2px !important;
}

@media (max-height: 820px) and (min-width: 701px) {
    #modalNovaNota > .modal {
        max-height: 96vh !important;
        gap: 10px !important;
    }
    #modalNovaNota #inputNotaConteudo {
        min-height: 300px !important;
        height: 40vh !important;
        max-height: 48vh !important;
    }
}

@media (max-width: 700px) {
    #modalNovaNota {
        padding: 8px !important;
        align-items: center !important;
    }
    #modalNovaNota > .modal {
        width: 100% !important;
        max-width: none !important;
        max-height: 97vh !important;
        padding: 16px !important;
        gap: 11px !important;
    }
    #modalNovaNota #inputNotaConteudo {
        min-height: 320px !important;
        height: 44vh !important;
        max-height: 56vh !important;
        padding: 14px !important;
        font-size: .96rem !important;
        line-height: 1.55 !important;
    }
    #modalNovaNota .modal-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        width: 100% !important;
    }
    #modalNovaNota .modal-actions .btn {
        width: 100% !important;
        justify-content: center !important;
        min-width: 0 !important;
    }
}

@media (max-width: 430px) {
    #modalNovaNota #inputNotaConteudo {
        min-height: 280px !important;
        height: 40vh !important;
    }
}

/* V10.8.0 — Editor rico de anotações */
#modalNovaNota .note-rich-editor-group {
    gap: 8px !important;
}

#modalNovaNota .note-format-toolbar {
    display: flex !important;
    align-items: center !important;
    gap: 7px !important;
    width: 100% !important;
    min-height: 46px !important;
    padding: 6px 8px !important;
    margin: 0 !important;
    border: 1px solid var(--border-color) !important;
    border-bottom: 0 !important;
    border-radius: 10px 10px 0 0 !important;
    background: rgba(15, 23, 42, .55) !important;
    box-sizing: border-box !important;
    flex-wrap: wrap !important;
}

#modalNovaNota .note-format-btn {
    appearance: none !important;
    width: 34px !important;
    height: 32px !important;
    min-width: 34px !important;
    display: inline-grid !important;
    place-items: center !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 1px solid rgba(100, 116, 139, .45) !important;
    border-radius: 7px !important;
    background: rgba(30, 41, 59, .68) !important;
    color: var(--text-color) !important;
    font-size: .92rem !important;
    line-height: 1 !important;
    cursor: pointer !important;
}

#modalNovaNota .note-format-btn:hover,
#modalNovaNota .note-format-btn:focus-visible,
#modalNovaNota .note-format-btn.active {
    border-color: rgba(45, 212, 191, .82) !important;
    background: rgba(20, 184, 166, .13) !important;
    color: #5eead4 !important;
    outline: none !important;
}

#modalNovaNota .note-toolbar-underline {
    text-decoration: underline !important;
    text-underline-offset: 2px !important;
}

#modalNovaNota .note-toolbar-divider {
    width: 1px !important;
    height: 24px !important;
    margin: 0 3px !important;
    background: rgba(100, 116, 139, .4) !important;
}

#modalNovaNota .note-font-size-control {
    display: inline-flex !important;
    align-items: center !important;
    gap: 7px !important;
    margin-left: 1px !important;
    color: #94a3b8 !important;
    font-size: .76rem !important;
    font-weight: 700 !important;
}

#modalNovaNota .note-font-size-control select {
    width: 72px !important;
    min-width: 72px !important;
    height: 32px !important;
    padding: 3px 24px 3px 8px !important;
    border-radius: 7px !important;
    font-size: .82rem !important;
    font-weight: 700 !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor {
    width: 100% !important;
    min-height: clamp(360px, 46vh, 620px) !important;
    height: clamp(360px, 46vh, 620px) !important;
    max-height: 62vh !important;
    padding: 16px 18px !important;
    margin: 0 !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 0 0 10px 10px !important;
    background: rgba(5, 18, 33, .55) !important;
    color: var(--text-color) !important;
    font-size: 16px !important;
    line-height: 1.6 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    outline: none !important;
    white-space: pre-wrap !important;
    overflow-wrap: anywhere !important;
    box-sizing: border-box !important;
    caret-color: #5eead4 !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor:focus {
    border-color: rgba(45, 212, 191, .68) !important;
    box-shadow: 0 0 0 1px rgba(45, 212, 191, .12) inset !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor:empty::before {
    content: attr(data-placeholder) !important;
    color: #64748b !important;
    pointer-events: none !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor b,
#modalNovaNota #inputNotaConteudo.note-rich-editor strong,
.note-rich-content b,
.note-rich-content strong {
    font-weight: 800 !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor i,
#modalNovaNota #inputNotaConteudo.note-rich-editor em,
.note-rich-content i,
.note-rich-content em {
    font-style: italic !important;
}

#modalNovaNota #inputNotaConteudo.note-rich-editor u,
.note-rich-content u {
    text-decoration: underline !important;
    text-underline-offset: 2px !important;
}

.note-card-body.note-rich-content {
    white-space: pre-wrap !important;
    overflow-wrap: anywhere !important;
}

body.light-mode #modalNovaNota .note-format-toolbar {
    background: #f8fafc !important;
}
body.light-mode #modalNovaNota .note-format-btn {
    background: #ffffff !important;
    border-color: #cbd5e1 !important;
}
body.light-mode #modalNovaNota .note-format-btn:hover,
body.light-mode #modalNovaNota .note-format-btn:focus-visible,
body.light-mode #modalNovaNota .note-format-btn.active {
    background: #ecfeff !important;
    border-color: #2dd4bf !important;
    color: #0f766e !important;
}
body.light-mode #modalNovaNota #inputNotaConteudo.note-rich-editor {
    background: #ffffff !important;
}

@media (max-height: 820px) and (min-width: 701px) {
    #modalNovaNota #inputNotaConteudo.note-rich-editor {
        min-height: 300px !important;
        height: 40vh !important;
        max-height: 48vh !important;
    }
}

@media (max-width: 700px) {
    #modalNovaNota .note-format-toolbar {
        gap: 6px !important;
        padding: 6px !important;
    }
    #modalNovaNota .note-font-size-control {
        margin-left: 0 !important;
    }
    #modalNovaNota #inputNotaConteudo.note-rich-editor {
        min-height: 320px !important;
        height: 44vh !important;
        max-height: 56vh !important;
        padding: 14px !important;
        font-size: 16px !important;
        line-height: 1.55 !important;
    }
}

@media (max-width: 430px) {
    #modalNovaNota .note-font-size-control > span {
        display: none !important;
    }
    #modalNovaNota #inputNotaConteudo.note-rich-editor {
        min-height: 280px !important;
        height: 40vh !important;
    }
}

/* V10.8.1 — Navegação orientada ao objetivo: Cronograma, Flashcards e Anotações */
:root {
    --workspace-mobile-top-gap: 12px;
}

.tab-workspace-anchor {
    scroll-margin-top: 18px;
}

/* Desktop e mobile usam a mesma ordem visual dos destinos principais. */
.header-nav-tabs .tab-btn,
.mobile-bottom-nav .mobile-nav-btn[data-tab] {
    touch-action: manipulation;
}

/* O destino ativo recebe um respiro previsível na chegada, sem alterar o card. */
#calendarWorkspace,
#flashcardsWorkspace,
#notesWorkspace {
    position: relative;
}

@media (min-width: 901px) {
    #calendarWorkspace,
    #flashcardsWorkspace,
    #notesWorkspace {
        scroll-margin-top: calc(var(--desktop-tabs-sticky-top, 112px) + 18px);
    }
}

@media (max-width: 900px) {
    #calendarWorkspace,
    #flashcardsWorkspace,
    #notesWorkspace {
        scroll-margin-top: var(--workspace-mobile-top-gap);
    }
}


/* V10.8.2 — Edital: ações de exclusão independentes */
#tab-edital .edital-manual-actions,
#tab-edital .manual-entry-actions { gap:8px; flex-wrap:wrap; }
@media (max-width:700px) {
    #tab-edital button[onclick="excluirMateriaEspecifica()"],
    #tab-edital button[onclick="excluirAssuntoEspecifico()"] { flex:1 1 145px; justify-content:center; }
}


/* V10.9.2 — Pomodoro: seleção de contexto antes do foco manual */
#modalPomodoroContext .pomodoro-context-help {
    margin:0 0 14px; color:var(--modern-muted,#94a3b8); font-size:.86rem; line-height:1.5;
}
#modalPomodoroContext .form-group { margin-bottom:12px; }
#modalPomodoroContext select { width:100%; }
@media (max-width:600px) {
    #modalPomodoroContext .modal { width:min(94vw,620px); padding:16px; }
    #modalPomodoroContext .modal-actions { display:grid; grid-template-columns:1fr; gap:8px; }
    #modalPomodoroContext .modal-actions .btn { width:100%; justify-content:center; }
}
