/* Story map layout for the Cim se zabyvame page. */

.topics-container {
    max-width: 1060px;
}

.topics-highlight p,
.topics-map-item p,
.topics-closing p {
    color: var(--color-muted);
    font-size: 17px;
    line-height: 1.82;
}

.topics-highlight {
    max-width: 780px;
    margin: 0;
    padding: 26px 30px;
    border: 1px solid rgba(154, 122, 50, 0.18);
    border-radius: var(--radius-md);
    background: #fffaf1;
}

.topics-highlight p {
    margin: 0;
    color: var(--color-text);
    font-family: var(--font-heading);
    font-size: clamp(21px, 2.3vw, 27px);
    line-height: 1.45;
}

.topics-map {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
    margin-top: 0;
}

.topics-highlight + .topics-map {
    margin-top: 46px;
}

.topics-map-item {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    min-width: 0;
    padding: 24px;
    border: 1px solid rgba(154, 122, 50, 0.16);
    border-radius: var(--radius-md);
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(40, 35, 29, 0.03);
}

.topics-map-item.is-wide {
    grid-column: span 2;
}

.topics-map-item-image {
    margin: 0 0 16px;
}

.topics-map-item-image img {
    display: block;
    width: 100%;
    max-height: 180px;
    border-radius: calc(var(--radius-md) - 2px);
    object-fit: cover;
}

.topics-map-item h2 {
    margin: 0 0 12px;
    font-family: var(--font-heading);
    font-size: clamp(22px, 2.1vw, 27px);
    font-weight: 500;
    line-height: 1.2;
}

.topics-map-item p {
    margin: 0;
}

.topics-map-item-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 16px;
    margin-top: auto;
    padding-top: 20px;
}

.topics-map-item-links a,
.topics-project-map-links a {
    color: var(--color-accent);
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.topics-map-item-links a:hover,
.topics-project-map-links a:hover {
    color: var(--color-text);
}

.topics-project-map {
    scroll-margin-top: 28px;
    margin-top: 54px;
    padding: 30px;
    border: 1px solid rgba(154, 122, 50, 0.18);
    border-radius: var(--radius-md);
    background: #fffdf8;
}

.topics-project-map-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    align-items: start;
    gap: clamp(28px, 4vw, 48px);
    max-width: 1080px;
    margin-inline: auto;
}

.topics-project-map-content,
.topics-project-map-visual {
    min-width: 0;
}

.topics-project-map h2 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(25px, 2.7vw, 34px);
    font-weight: 500;
    line-height: 1.2;
}

.topics-project-map-text {
    margin-top: 18px;
}

.topics-project-map-text p {
    margin: 0 0 14px;
    color: var(--color-muted);
    font-size: 17px;
    line-height: 1.82;
}

.topics-project-map-text p:last-child {
    margin-bottom: 0;
}

.topics-project-map-guide {
    margin: 20px 0 0;
}

.topics-project-map-guide a,
.topics-project-map-links a {
    color: var(--color-accent);
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.topics-project-map-guide a:hover,
.topics-project-map-links a:hover {
    color: var(--color-text);
}

.topics-project-map-image {
    width: 100%;
    margin: 0;
    overflow: hidden;
    border: 1px solid rgba(154, 122, 50, 0.2);
    border-radius: calc(var(--radius-md) - 2px);
    background: #ffffff;
}

.topics-project-map-image a,
.topics-project-map-image img {
    display: block;
}

.topics-project-map-image img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.topics-project-map-links {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin: 14px 0 0;
}

@media (max-width: 800px) {
    .topics-project-map-layout {
        grid-template-columns: 1fr;
        gap: 26px;
    }
}

.topics-atmosphere {
    margin: 54px 0 0;
}

.topics-atmosphere img {
    display: block;
    width: 100%;
    max-height: 390px;
    border-radius: 16px;
    object-fit: cover;
    box-shadow: 0 18px 42px rgba(40, 35, 29, 0.08);
}

.topics-closing {
    max-width: 780px;
    margin-top: 58px;
    padding: 28px 30px;
    border: 1px solid rgba(154, 122, 50, 0.16);
    border-radius: var(--radius-md);
    background: #fffdf8;
}

.topics-next-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.topics-next-links a {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 9px 15px;
    border: 1px solid rgba(154, 122, 50, 0.26);
    border-radius: var(--radius-pill);
    color: var(--color-accent);
    font-family: var(--font-ui);
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
}

.topics-next-links a:hover {
    background: rgba(154, 122, 50, 0.08);
}

@media (max-width: 640px) {
    .topics-highlight {
        padding: 22px;
    }

    .topics-map {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .topics-highlight + .topics-map {
        margin-top: 38px;
    }

    .topics-map-item {
        padding: 22px;
    }

    .topics-map-item.is-wide {
        grid-column: auto;
    }

    .topics-project-map {
        margin-top: 42px;
        padding: 24px 22px;
    }

    .topics-project-map-links {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .topics-closing {
        padding: 24px 22px;
    }

    .topics-next-links a {
        width: 100%;
    }
}
