/* Банк заданий: сетка как на logilea.ru/tasks/, палитра Литфокса */

.lit-tasks-layout {
    display: grid;
    grid-template-columns: 1fr 1fr 1.15fr;
    gap: 25px;
    justify-content: center;
    align-items: stretch;
    min-height: 70vh;
    margin-bottom: 40px;
    box-sizing: border-box;
}

.lit-tasks-col {
    display: flex;
    flex-direction: column;
    gap: 25px;
    min-height: 0;
}

.lit-tasks-col--wide .tasks-block-link {
    flex: 1;
    min-height: calc(85vh - 40px);
    height: auto;
}

.lit-tasks-col--stack .tasks-block-link {
    flex: 1;
    min-height: 220px;
    height: calc((85vh - 40px - 25px) / 2);
    max-height: 520px;
}

.tasks-block-link {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-end;
    border-radius: 40px;
    text-decoration: none;
    transition: box-shadow 0.2s, transform 0.2s;
    box-shadow: 0 4px 24px 0 rgba(44, 63, 112, 0.08);
    cursor: pointer;
    position: relative;
    padding: 40px 32px 32px 32px;
    overflow: hidden;
    box-sizing: border-box;
    color: inherit;
}

.tasks-block-link:hover:not(.is-disabled) {
    box-shadow: 0 8px 32px 0 rgba(44, 63, 112, 0.14);
    transform: translateY(-4px) scale(1.02);
}

.tasks-block-link.is-disabled {
    cursor: not-allowed;
    opacity: 0.62;
    transform: none;
    box-shadow: 0 2px 12px rgba(44, 63, 112, 0.05);
    background: var(--color-meringue) !important;
    color: #6b7280 !important;
    border: 2px dashed var(--color-buttercream);
}

.tasks-block-link.is-disabled:hover {
    transform: none;
    box-shadow: 0 2px 12px rgba(44, 63, 112, 0.05);
}

.tasks-block-link--lit-oge {
    background: var(--color-blueberry);
    color: var(--color-white);
}

.tasks-block-link--lit-ege {
    background: var(--color-strawberry);
    color: var(--color-white);
}

.tasks-block-link--literature-hub {
    background: var(--color-white);
    color: #2c3e50;
    border: 1px solid var(--color-buttercream);
}

.tasks-block-title {
    font-size: clamp(28px, 3.2vw, 48px);
    font-family: "Manrope", sans-serif;
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: 15px;
    margin-top: 0;
    line-height: 1.1;
    display: block;
}

.tasks-block-desc {
    font-size: 1.08rem;
    font-family: "Manrope", sans-serif;
    font-weight: 400;
    line-height: 1.35;
    opacity: 0.92;
    margin-bottom: 0;
    display: block;
}

.tasks-block-link--literature-hub .tasks-block-desc {
    color: var(--color-text-muted);
}

.tasks-block-info {
    position: absolute;
    left: 32px;
    /* место под нижний padding + высота кнопки + отступ от текста */
    bottom: calc(32px + 60px + 28px);
    text-align: left;
    z-index: 1;
    max-width: 78%;
}

.tasks-block-arrow-btn {
    margin-top: 0;
    flex-shrink: 0;
    width: 100%;
    height: 60px;
    background: var(--color-violet);
    border: none;
    outline: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: var(--color-white);
    border-radius: 30px;
    font-family: "Manrope", sans-serif;
    font-weight: 500;
    gap: 12px;
    transition: background 0.2s, color 0.2s;
}

.tasks-block-link--lit-oge .tasks-block-arrow-btn {
    background: var(--color-strawberry);
    color: var(--color-white);
}

.tasks-block-link--lit-oge .tasks-block-arrow-btn:hover {
    background: var(--color-strawberry-hover);
}

.tasks-block-link--lit-ege .tasks-block-arrow-btn {
    background: var(--color-white);
    color: var(--color-strawberry);
    border: 2px solid rgba(255, 255, 255, 0.85);
}

.tasks-block-link--literature-hub .tasks-block-arrow-btn {
    background: var(--color-strawberry);
    color: var(--color-white);
}

.tasks-block-link--literature-hub .tasks-block-arrow-btn:hover {
    background: var(--color-strawberry-hover);
}

.tasks-block-arrow-btn .hero-button-arrow {
    width: 4em;
    height: 3em;
    margin-left: 8px;
    vertical-align: middle;
}

.tasks-block-link.is-disabled .tasks-block-arrow-btn {
    background: #d1d5db;
    color: #6b7280;
    cursor: not-allowed;
    border: none;
}

.tasks-block-link .corner-arrow {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    pointer-events: none;
}

.tasks-block-link .corner-arrow svg {
    width: 52px;
    height: 52px;
    stroke-width: 4px;
    fill: none;
    color: var(--color-violet);
}

.tasks-block-link--lit-oge .corner-arrow svg {
    color: #fff;
}

.tasks-block-link--lit-ege .corner-arrow svg {
    color: rgba(255, 255, 255, 0.95);
}

.tasks-block-link.is-disabled .corner-arrow svg {
    color: #9ca3af;
}

/* Ноутбуки: компактнее заголовок и описание при широкой трёхколоночной сетке */
@media (max-width: 1600px) {
    .tasks-block-title {
        font-size: clamp(22px, 2.35vw, 36px);
        margin-bottom: 12px;
    }

    .tasks-block-desc {
        font-size: 1rem;
        line-height: 1.32;
    }

    .tasks-block-info {
        bottom: calc(32px + 60px + 22px);
    }
}

@media (max-width: 1200px) {
    .lit-tasks-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .lit-tasks-col--stack .tasks-block-link {
        width: 100%;
        min-height: 200px;
        height: 280px;
        max-height: none;
    }

    .lit-tasks-col--wide .tasks-block-link {
        min-height: 300px;
        height: auto;
    }

    .tasks-block-info {
        max-width: 88%;
        bottom: calc(32px + 60px + 24px);
    }

    .tasks-block-title {
        margin-top: 8px;
    }
}

/* Хаб «Тесты» ЕГЭ: две карточки как на /tasks/, в ряд по 50%; высота 400px на ноуте */
.lit-tasks-layout--ege-tests-hub {
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    min-height: auto;
    margin-bottom: 48px;
    box-sizing: border-box;
}

.lit-tasks-layout--ege-tests-hub > .tasks-block-link {
    min-width: 0;
    width: 100%;
}

@media (min-width: 721px) {
    .lit-tasks-layout--ege-tests-hub > .tasks-block-link {
        height: 400px;
        min-height: 400px;
        max-height: none;
    }
}

@media (max-width: 720px) {
    .lit-tasks-layout--ege-tests-hub {
        grid-template-columns: 1fr;
    }

    .lit-tasks-layout--ege-tests-hub > .tasks-block-link {
        height: 280px;
        min-height: 260px;
        max-height: none;
    }
}
