.modules-title {
    font-family: 'Alice', serif;
    font-weight: 500;
    font-size: 38px;
    color: #45568E;
    text-align: center;
    margin-top: 2rem;
    margin-bottom: 0.5rem;
}

.modules-decorator {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: #4a6491;
    margin: 15px auto;
}

/* Grid de Cards */
.modules-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    /* Adiciona um pouco de margem se necessário, mas o container já cuida disso */
    margin-top: 1.5rem;
}

/* Card Individual */
.module-card {
    background-color: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 300px;
    border-width: 4px;
    border-style: solid;
    cursor: pointer;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    text-align: left;
}

.module-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    transform: translateY(-5px);
}

.module-card-image-placeholder {
    width: 128px;
    height: 128px;
    border-radius: 50%;
    margin: 0 auto 1.5rem auto;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}
.module-card-icon{
    width: 120px;
    height: 120px;
    /* border: solid red 1px; */
    margin: 0 auto;
}

.module-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    margin-bottom: 0.75rem;
    font-family: 'Rubik', sans-serif;
}

.module-card-preview-text {
    font-size: 0.9rem;
    color: #475569;
    text-align: center;

    height: 5.6rem;

    /* Truncamento */
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'Rubik', sans-serif;
}

.module-card-link {
    font-size: 0.95rem;
    font-weight: 600;
    color: #2563eb;
    text-align: center;
    display: block;
    margin-top: 1rem;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
}

.module-card-link:hover {
    text-decoration: underline;
}

/* --- Estilos do Modal (Globais para a página) --- */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 1rem;
}

.modal-backdrop.hidden {
    display: none;
}

.modal-content {
    background-color: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 1100px;
    height: 95vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #e2e8f0;
    background: white;
}

.modal-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    font-family: 'Alice', serif;
    font-weight: 700;
}

.modal-close {
    font-size: 2.5rem;
    font-weight: 700;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s ease;
    background: none;
    border: none;
}

.modal-close:hover {
    color: #1e293b;
}

.modal-body {
    padding: 2rem;
    overflow-y: auto;
    flex-grow: 1;
    font-family: 'Inter', sans-serif;
}

.modal-body p {
    font-family: 'Rubik', serif;
    font-size: 1.1rem;
    color: #334155;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.modal-body h3 {
    font-family: 'Rubik', serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: #1e293b;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.modal-body img {
    width: 100%;
    max-width: 600px;
    height: auto;
    display: block;
    margin: 1.5rem auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.modal-body ul,
.modal-body ol {
    font-size: 1.1rem;
    color: #334155;
    margin: 1rem 0 1rem 2rem;
    padding-left: 1rem;
}
.linha{
    height: 2px;
    background-color: #1e293b;
    width: 80%;
    margin: 2.5rem auto;
}
.modal-body h1{
    font-family: 'Rubik', serif;
    font-weight: 600;
    text-align: center;
    color: #1e293b;
}
.modal-body h4{
    font-family: 'Rubik', serif;
    font-size: 22px;
    font-weight: 600;
    text-align: center;
    color: #1e293b;
    margin: 0.5rem;
}
/* Responsividade */
@media (max-width: 768px) {
    .modules-title {
        font-size: 2.5rem;
    }

    .module-card {
        width: 100%;
        max-width: 340px;
    }

    .modal-content {
        height: 90vh;
    }
}