﻿/* ============================= */
/* VIDEO MODAL & THUMBNAILS      */
/* ============================= */
.video-thumbnails-container {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    justify-content: center;
}

.video-thumbnail-card {
    flex: 1;
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    background-color: #111;
    border: 1px solid #333;
    aspect-ratio: 16 / 9;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.video-thumbnail-card:hover {
    transform: scale(1.02);
    border-color: #22d3ee;
}

.video-thumbnail-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.video-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.video-thumbnail-card:hover .video-play-overlay {
    background: rgba(0, 0, 0, 0.2);
}

.video-play-btn {
    width: 48px;
    height: 48px;
    background-color: rgba(34, 211, 238, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.video-thumbnail-card:hover .video-play-btn {
    transform: scale(1.1);
    background-color: #22d3ee;
}

.video-play-btn::after {
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-left: 14px solid #000;
    margin-left: 3px;
}

.video-thumb-title {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 4px 8px;
    background: linear-gradient(transparent, rgba(0,0,0,0.85));
    color: #fff;
    font-size: 11px;
    font-weight: bold;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Fullscreen Video Player Modal */
.video-player-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh; /* fallback */
    height: 100dvh;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.video-player-content {
    position: relative;
    max-width: 900px;
    width: 100%;
    background: #000;
    border: 1px solid #333;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    display: flex;
    flex-direction: column;
}

.video-player-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: #111;
    border-bottom: 1px solid #222;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
}

.video-player-close {
    background: transparent;
    border: none;
    color: #aaa;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
    transition: color 0.2s ease;
}

.video-player-close:hover {
    color: #fff;
}

.video-player-body {
    position: relative;
    width: 100%;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.video-player-body video {
    width: 100%;
    max-height: 75vh;
    display: block;
    outline: none;
}

/* ============================= */
/* TEMA PRETO PROFUNDO */
/* ============================= */

/* ============================= */
/* TITULOS */
/* ============================= */

h1 {
    margin-bottom: 12px;
    font-weight: 600;
    text-align: center;
}

h2 {
    margin-top: 0;
}

/* ============================= */
/* PROGRESS CONTAINER */
/* ============================= */

.progress-container {
    padding: 10px 14px;
    background-color: var(--bg-elevated);
    border: 1px solid var(--bg-hover);
    border-radius: 4px;
    margin-bottom: 10px;
}

.progress-info {
    margin-bottom: 10px;
    font-size: 13px;
    color: #ccc;
}

.progress-bar-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.progress-bar {
    flex: 1;
    height: 24px;
    background-color: var(--bg-hover);
    border-radius: 4px;
    display: flex;
    overflow: hidden;
    border: 1px solid var(--border);
    position: relative;
}

.progress-segment {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #000;
    font-weight: bold;
    transition: width 0.3s ease;
}

.progress-segment.aprobadas {
    background-color: var(--aprobada);
}

.progress-segment.regularizadas {
    background-color: var(--regularizada);
}

.progress-segment.optativas {
    background-color: var(--cursando);
}

.progress-segment.puede-cursar {
    background-color: #666666;
}

.progress-segment.cursando {
    background-color: #c0c0c0;
}

.progress-percent {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 40px;
    text-align: right;
}


.input-error {
    border: 1px solid red !important;
}

.vacuna-form {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
}

.vacuna-form select,
.vacuna-form input {
    flex: 1;
    padding: 6px 8px;
    border: 1px solid var(--bg-input);
    background-color: var(--bg-hover);
    color: white;
    border-radius: 4px;
    font-size: 14px;
}

.vacuna-form button {
    padding: 6px 10px;
    background-color: var(--bg-card);
    border: 1px solid var(--bg-input);
    color: white;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}


.extension-form button {
    padding: 6px 10px;
    background-color: var(--bg-card);
    border: 1px solid var(--bg-input);
    color: white;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.extension-form button:hover {
    background-color: #1c1c1c;
}

.extension-form input {
    flex: 1;
    padding: 6px 8px;
    border: 1px solid var(--bg-input);
    background-color: var(--bg-card);
    color: white;
    border-radius: 4px;
    font-size: 14px;
}


/* texto de proyectos de extensi�n */
.extension-nombre {
    color: #86efac;
}

/* texto de materias optativas */
.optativa-nombre {
    color: var(--cursando);
}

/* ============================= */
/* TOP BAR VACUNAS */
/* ============================= */

.top-bar-left,
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.year-input-group {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex: 1;
    gap: 10px;
}

.year-input-group label {
    font-size: 16px;
    color: #ccc;
    font-weight: 500;
}

.year-input-group input {
    padding: 10px 12px;
    border: 1px solid var(--border);
    background-color: var(--bg-card);
    color: white;
    border-radius: 6px;
    font-size: 16px;
    width: 80px;
    height: 40px;
    box-sizing: border-box;
    text-align: center;
}

.year-input-group input:focus {
    border-color: var(--cursando);
    outline: none;
}

.btn-help {
    background-color: transparent !important;
    border: 1px solid var(--border) !important;
    color: var(--cursando) !important;
    font-weight: bold;
    font-size: 11px !important;
    padding: 0 12px !important;
    border-radius: 4px;
    height: 37px;
    line-height: 35px;
    letter-spacing: 1px;
}

.btn-help:hover {
    background-color: #22d3ee11 !important;
    border-color: var(--cursando) !important;
}

.btn-reset-hold {
    position: relative;
    overflow: hidden;
    background-color: transparent !important;
    border: 1px solid var(--border-strong) !important;
    color: #f87171 !important;
    font-weight: bold;
    font-size: 12px !important;
    padding: 0 16px !important;
    height: 37px;
    line-height: 35px;
    cursor: pointer;
    border-radius: 4px;
    transition: border-color 0.2s ease;
    -webkit-user-select: none;
    user-select: none;
    touch-action: manipulation;
}

.btn-reset-hold::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 0;
    background: var(--danger);
    transition: width 1.5s linear;
}

.btn-reset-hold.holding::after {
    width: 100%;
}

.btn-reset-hold.holding {
    border-color: var(--danger) !important;
    background-color: #ef444411 !important;
}

.btn-reset-hold:hover {
    border-color: var(--text-dim) !important;
}

.btn-primary {
    background-color: transparent !important;
    border: 1px solid var(--border-strong) !important;
    color: #fff !important;
    font-weight: bold;
    font-size: 12px !important;
    padding: 8px 16px !important;
    letter-spacing: 0.5px;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background-color: #ffffff11 !important;
    border-color: var(--text-dim) !important;
}

/* ============================= */
/* OPTATIVAS BOX */
/* ============================= */

.listas {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.listas div {
    background-color: transparent;
    border: none;
}

/* ============================= */
/* ITEMS */
/* ============================= */

ul:not(.app-navbar-list) {
    padding-left: 8px;
    margin: 6px 0;
}

li:not(.app-navbar-list li) {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 14px;
}

/* Item row para no puede cursar - dois boxes na mesma linha */
li.item-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
}

.item-box {
    display: flex;
    align-items: center;
    gap: 4px;
}

.item-nombre {
    flex: 0 1 300px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.item-requisitos {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    flex: 1 0 auto;
    align-items: center;
    gap: 8px;
}

/* container holding progress bar/count and buttons, pushed to right */
.right-group {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

/* Container info-row para no puede cursar */
.info-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    width: 100%;
    justify-content: space-between;
}

/* Progress fica �"oǭ esquerda */
.info-row .progress {
    margin-right: auto;
}

/* Nome da mat�"o��ria */
li span:first-child {
    flex: 1;
}

/* tag de a�"o�-'o */
.anio-tag {
    font-size: 12px;
    color: var(--text-muted);
    opacity: 0.8;
    margin-left: 8px;
    font-weight: normal;
    white-space: normal;
    min-width: 50px;
}

/* ============================= */
/* BOT�"o��ES DE ESTADO */
/* ============================= */

.btn-warning-faltantes {
    background: none !important;
    border: none !important;
    color: var(--puede-cursar) !important;
    cursor: pointer;
    font-size: 16px;
    padding: 0 4px !important;
    margin-left: 4px;
    display: inline-block !important; /* For��ar exibi��ǜo */
}

.btn-warning-faltantes:hover {
    transform: scale(1.2);
    background: transparent !important;
}

li button {
    font-size: 12px;
    padding: 4px 6px;
    background-color: transparent;
    border: none;
}

/* Star button for optativas */
.btn-star-optativa {
    font-size: 14px !important;
    padding: 2px 6px !important;
    background-color: transparent !important;
    border: none !important;
    cursor: pointer;
    transition: transform 0.15s ease, filter 0.15s ease;
    line-height: 1;
}

.btn-star-optativa:hover {
    transform: scale(1.3);
    filter: drop-shadow(0 0 4px #facc15);
}

/* ============================= */
/* MODAL / POPUP */
/* ============================= */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 20px;
}

.modal-content {
    background-color: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.modal-content h3 {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--puede-cursar);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-close-x {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none !important;
    border: none !important;
    color: var(--text-muted) !important;
    font-size: 20px !important;
    cursor: pointer;
    padding: 0 !important;
    line-height: 1;
}

.modal-close-x:hover {
    color: #fff !important;
}

.modal-content ul {
    list-style: none;
    padding: 0;
    margin: 15px 0;
    border-top: 1px solid var(--bg-input);
}

.modal-content li {
    padding: 10px 0;
    border-bottom: 1px solid var(--bg-input);
    background: transparent;
    font-size: 14px;
    color: #ccc;
    display: block;
}

.modal-content button {
    cursor: pointer;
    transition: background 0.2s;
}

.modal-content button:hover {
    background-color: var(--border) !important;
}

/* Aprovar */
li button:nth-child(2) {
    color: var(--aprobada);
}

/* Regularizar */
li button:nth-child(3) {
    color: var(--puede-cursar);
}

/* Reset */
li button:nth-child(4) {
    color: var(--danger);
}

li button:hover {
    background-color: var(--bg-input);
}

/* Ocultar los botones dentro de "No puede cursar" */
#noPuedeCursar li button,
#noPuedeCursar-obligatorias li button,
#noPuedeCursar-optativas li button {
    display: none;
}

/* ============================= */
/* REGULARIZADAS SUBDIVISIONES */
/* ============================= */

.regularizadas-box {
    background-color: var(--bg-elevated);
    padding: 10px;
    border: 1px solid var(--bg-card);
    border-radius: 4px;
}

/* Cada se�"o���"oǧo interna */
.sub-section {
    margin-top: 4px;
}

/* T�"o��tulo interno menor */
.sub-section h4 {
    margin-bottom: 8px;
    font-size: 15px;
    opacity: 0.8;
}

/* Header colaps�"o��vel para subsections de optativas */
.collapsible-header {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 0;
    transition: opacity 0.2s ease;
}

.collapsible-header:hover {
    opacity: 0.9;
}

/* Conte�"o�'do colaps�"o��vel dentro de sub-sections */
.sub-content {
    overflow: hidden;
    max-height: 9999px;
    opacity: 1;
    transition:
        max-height 0.3s ease,
        opacity 0.2s ease;
}

/* Quando sub-content est�"o�� colapsado */
.sub-content.collapsed {
    max-height: 0;
    opacity: 0;
}

/* Esconde automaticamente quando vazio */
.sub-section:has(ul:empty) {
    display: none;
}

/* Remove espa�"o��o se estiver vazio */
.sub-section ul:empty + * {
    margin-top: 0;
}

/* barra de progresso ao lado direito */
.progress {
    margin-left: 6px;
    opacity: 0.9;
    font-size: 12px;
}

/* missing requirement label */
.falta {
    font-size: 12px;
    opacity: 0.75;
    margin-right: 4px;
    white-space: normal;
}

/* emoji progress spacing */
.progress-emoji {
    margin-left: 4px;
}

.progress-bar-inner {
    height: 100%;
    background-color: #fff;
    transition: width 0.3s;
    border-radius: 3px;
}

/* when only one requirement remains */
.progress-bar.almost .progress-bar-inner {
    background-color: var(--puede-cursar); /* amarillo */
}

/* ============================= */
/* FECHAS DE FINALES */
/* ============================= */

.fechas-proximas {
    display: inline;
    font-size: 12px;
    color: var(--cursando) !important;
    margin-left: 4px;
}

.fechas-proximas.urgente {
    color: var(--regularizada);
    font-weight: bold;
}

.btn-calendario {
    background: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    color: var(--cursando) !important;
    cursor: pointer;
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 20px;
    vertical-align: middle;
    transition: box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    box-shadow: inset 1px 1px 2px rgba(255, 255, 255, 0.15), 0 2px 4px rgba(34, 211, 238, 0.2);
}

.btn-calendario:hover {
    background: #1a1a2e !important;
    border-color: var(--cursando) !important;
    box-shadow: inset 1px 1px 3px rgba(255, 255, 255, 0.2), 0 2px 8px rgba(34, 211, 238, 0.35);
}

.catedra-select {
    width: 100%;
    padding: 8px 10px;
    margin-bottom: 15px;
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    color: #fff;
    border-radius: 4px;
    font-size: 14px;
}

.fechas-section-title {
    font-size: 13px;
    color: var(--cursando);
    margin: 15px 0 8px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fecha-item {
    font-weight: bold;
    color: #fff;
}

.fecha-item-anterior {
    color: var(--text-muted);
}

.fechas-container {
    max-height: 300px;
    overflow-y: auto;
}

/* ============================= */
/* BOX COLAPS�"oǬVEL AJUSTADO */
/* ============================= */

.box {
    padding: 4px 0;
    border: none;
    background-color: transparent;
}


.box h3 {
    margin-left: 0;
    cursor: pointer;
    user-select: none;
    -webkit-touch-callout: none;
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 10px;
    padding: 8px 12px;
    border-radius: 6px;
    border-left: 4px solid;
    transition: background 0.15s, filter 0.15s;
}

.box h3:hover {
    filter: brightness(1.2);
}

/* Collapsed box header dimmed */
.box:has(.box-content.collapsed) h3 {
    opacity: 0.7;
}

/* Color-coded box headers (Cartelera source-header style) */
.box-aprobadas h3 {
    color: var(--aprobada);
    background: rgba(34, 197, 94, 0.08);
    border-left-color: var(--aprobada);
}

.box-regularizadas h3 {
    color: var(--regularizada);
    background: rgba(249, 115, 22, 0.08);
    border-left-color: var(--regularizada);
}

.box-puede-cursar h3 {
    color: var(--puede-cursar);
    background: rgba(250, 204, 21, 0.08);
    border-left-color: var(--puede-cursar);
}

.box-proyectos h3 {
    color: var(--cursando);
    background: rgba(34, 211, 238, 0.08);
    border-left-color: var(--cursando);
}

.box-no-puede-cursar h3 {
    color: var(--text-dim);
    background: rgba(102, 102, 102, 0.08);
    border-left-color: var(--text-dim);
}

.box-count {
    color: #d0d0d0;
    font-size: 13px;
    font-weight: normal;
    margin-left: 4px;
}

/* Conte�"o�'do interno */
.box-content {
    overflow: hidden;
    max-height: 9999px;
    opacity: 1;
    transition:
        max-height 0.3s ease,
        opacity 0.2s ease;
}

/* Quando fechado */
.box-content.collapsed {
    max-height: 0;
    opacity: 0;
    margin: 0;
}

/* Indent sub-sections inside a box */
.box-content .sub-section {
    margin-left: 16px;
}


/* ============================= */
/* TOP BAR */
/* ============================= */

.top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

/* Hover effect on list items (desktop) */
@media (min-width: 769px) {
    .item-row:hover { background: rgba(255,255,255,0.06); }
    li:not(.item-row):hover { background: rgba(255,255,255,0.06); }
}

/* Cursando active background �?" subtle, no animation */
li.cursando-active { background: rgba(34,211,238,0.08); border-left: 2px solid rgba(34,211,238,0.4); }

/* Cursando toggle on main page */
.cursando-toggle-main { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; color: var(--text-faint); margin-left: 8px; white-space: nowrap; }
.cursando-switch-main { position: relative; display: inline-block; width: 28px; height: 16px; }
.cursando-switch-main input { opacity: 0; width: 0; height: 0; }
.cursando-slider-main { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: var(--border); border-radius: 16px; overflow: hidden; transition: background 0.2s; }
.cursando-slider-main::before { content: ""; position: absolute; height: 12px; width: 12px; left: 2px; bottom: 2px; background-color: var(--text-muted); border-radius: 50%; transition: transform 0.2s; }
.cursando-switch-main input:checked + .cursando-slider-main { background-color: rgba(34,211,238,0.6); }
.cursando-switch-main input:checked + .cursando-slider-main::before { transform: translateX(12px); background-color: var(--cursando); }

/* Abbreviate names switch */
.abbreviate-switch-wrap {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
}
.abbreviate-switch {
    position: relative;
    display: inline-block;
    width: 36px;
    height: 20px;
}
.abbreviate-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.abbreviate-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    transition: background 0.2s, border-color 0.2s;
}
.abbreviate-slider::before {
    content: "";
    position: absolute;
    height: 14px;
    width: 14px;
    left: 2px;
    bottom: 2px;
    background-color: var(--text-dim);
    border-radius: 50%;
    transition: transform 0.2s, background-color 0.2s;
}
.abbreviate-switch input:checked + .abbreviate-slider {
    background-color: var(--cursando);
    border-color: var(--cursando);
}
.abbreviate-switch input:checked + .abbreviate-slider::before {
    transform: translateX(16px);
    background-color: #fff;
}

/* Abbreviated mode styles */
.abbreviated-mode .optativa-nombre,
.abbreviated-mode li span:first-child:not(.optativa-nombre) {
    font-size: 16px; /* desktop - larger than base 14px */
}

@media (max-width: 768px) {

    /* Grid vira 1 coluna no celular */
    .listas {
        flex-direction: column;
        gap: 3px;
    }

    /* Top bar - layout vertical */
    .top-bar {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .top-bar-left,
    .top-bar-right {
        width: 100%;
        justify-content: center;
    }

    .year-input-group {
        width: 100%;
        justify-content: center;
    }

    .year-input-group label {
        font-size: 14px;
    }

    .year-input-group input {
        font-size: 16px;
        min-height: 44px;
    }

    .top-bar-left button,
    .top-bar-right button {
        flex: 1;
        min-height: 44px;
        font-size: 14px;
    }

    .btn-reset-hold {
        width: 100%;
    }

    .btn-help {
        width: 100%;
    }

    /* Legend box */
    .legend-box {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    /* Extension form - layout vertical */
    .extension-form {
        flex-direction: column;
        gap: 10px;
    }

    .extension-form input,
    .extension-form button {
        width: 100%;
        min-height: 44px; /* Tamanho m�"o��nimo para toque */
        font-size: 16px;
    }

    /* Inputs e buttons */
    select, input, button {
        max-width: 100%;
        min-height: 44px; /* Tamanho m�"o��nimo para toque */
        font-size: 16px;
    }

    /* LI ITEMS - layout para no pode cursar */
    li {
        display: flex;
        flex-wrap: wrap;
        padding: 12px; /* Mais espa�"o��amento para toque */
        margin-bottom: 10px;
    }

    /* No pode cursar - dois boxes em linhas separadas no mobile */
    li.item-row {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }

    .item-box {
        width: 100%;
    }

    .item-nombre {
        min-width: 100%;
        max-width: 100%;
        flex: none;
        font-size: 16px;
    }

    .item-requisitos {
        justify-content: flex-start;
        flex: none;
        width: 100%;
    }

    li span:first-child {
        width: 100%;
        margin-bottom: 6px;
        font-size: 16px;
    }

    /* Container da linha 2 (Falta + Emoji + Ano + Progress) */
    .info-row {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
        width: 100%;
        justify-content: flex-start;
    }

    .info-row .falta,
    .info-row .progress-emoji,
    .info-row .anio-tag,
    .info-row .progress {
        display: inline;
        width: auto;
        margin-left: 0;
        font-size: 14px;
    }

    /* Right group com bot�"o�?es alinhado �"oǭ direita */
    .right-group {
        display: flex;
        margin-left: auto;
        gap: 10px;
    }

    .fechas-proximas {
        margin-left: 0;
        margin-top: 6px;
        font-size: 14px;
    }

    li button {
        width: auto;
        min-height: 40px; /* Tamanho m�"o��nimo para toque */
        font-size: 16px;
    }

    /* Bot�"o�?es de a�"o���"oǧo espec�"o��ficos */
    .btn-warning-faltantes {
        min-width: 40px;
        min-height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .btn-calendario {
        font-size: 12px;
        padding: 5px 8px;
    }

    .btn-star-optativa {
        min-width: 40px;
        min-height: 40px;
        font-size: 18px !important;
        padding: 4px 8px !important;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Boxes */
    .box {
        margin-bottom: 6px;
        padding: 8px;
    }

    .box h3 {
        font-size: 18px;
        padding: 8px;
    }

    h1 {
        font-size: 22px; /* T�"o��tulo maior para mobile */
        text-align: center;
    }
    
    /* Barra de progresso */
    .progress-container {
        padding: 12px;
        margin-bottom: 15px;
    }
    
    .progress-bar {
        height: 28px; /* Barra mais alta para toque */
    }
    
    .progress-percent {
        font-size: 14px;
        min-width: 50px;
    }

    .cursando-toggle-main { font-size: 10px; gap: 2px; }

    /* Abbreviated mode mobile */
    .abbreviated-mode .optativa-nombre,
    .abbreviated-mode li span:first-child:not(.optativa-nombre) {
        font-size: 15px; /* mobile - larger than base 14px */
    }
}

/* ============================= */
/* PRIVACY NOTICE */
/* ============================= */

