.themelogik-history {
    position: relative;
    z-index: 0;
    width: 100%;
    display: block;
    min-height: 0;
    padding-block: clamp(6.1rem, 8vw, 7.4rem) clamp(3rem, 7vw, 5.5rem);
    background-color: color-mix(in srgb, var(--wp--preset--color--white, #fff) 88%, var(--wp--preset--color--black, #000) 12%);
    background-image: var(--themelogik-history-background-image, none);
    background-position: center top;
    background-repeat: repeat;
    background-size: auto;
}

.themelogik-history .themelogik-history__feature {
    width: 100%;
}

.themelogik-history .themelogik-history__inner {
    width: min(100%, 1600px);
    margin: 0 auto;
    padding-inline: clamp(1rem, 5vw, 4.75rem);
    box-sizing: border-box;
}

.themelogik-history .themelogik-history-card {
    position: relative;
    isolation: isolate;
    appearance: none;
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
    width: min(100%, 1220px);
    min-height: clamp(30rem, 54vw, 45rem);
    margin: 0 auto;
    padding: clamp(1.75rem, 4vw, 3rem);
    border: 0;
    border-radius: 2rem;
    background: color-mix(in srgb, var(--wp--preset--color--black, #000) 68%, transparent);
    color: var(--wp--preset--color--white, #fff);
    text-align: left;
    cursor: pointer;
    overflow: hidden;
    box-shadow: 0 28px 72px color-mix(in srgb, var(--wp--preset--color--black, #000) 18%, transparent);
}

.themelogik-history .themelogik-history-card:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 4px;
}

.themelogik-history .themelogik-history-card__media,
.themelogik-history .themelogik-history-card__overlay {
    position: absolute;
    inset: 0;
    border-radius: inherit;
}

.themelogik-history .themelogik-history-card__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1);
    transition: transform 0.35s ease;
}

.themelogik-history .themelogik-history-card:hover .themelogik-history-card__image,
.themelogik-history .themelogik-history-card:focus-visible .themelogik-history-card__image {
    transform: scale(1.03);
}

.themelogik-history .themelogik-history-card__overlay {
    background:
        linear-gradient(
            180deg,
            color-mix(in srgb, var(--wp--preset--color--black, #000) 20%, transparent) 0%,
            color-mix(in srgb, var(--wp--preset--color--black, #000) 38%, transparent) 36%,
            color-mix(in srgb, var(--wp--preset--color--black, #000) 74%, transparent) 100%
        );
}

.themelogik-history .themelogik-history-card__content {
    position: relative;
    z-index: 1;
    width: min(100%, 42rem);
    display: grid;
    gap: 1.2rem;
    align-items: start;
}

.themelogik-history .themelogik-history-card__header,
.themelogik-history .themelogik-history-card__body,
.themelogik-history .themelogik-history-card__actions,
.themelogik-history .themelogik-history-card__eyebrow,
.themelogik-history .themelogik-history-card__page-title,
.themelogik-history .themelogik-history-card__page-intro,
.themelogik-history .themelogik-history-card__title,
.themelogik-history .themelogik-history-card__text,
.themelogik-history .themelogik-history-card__cta {
    display: block;
}

.themelogik-history .themelogik-history-card__header {
    display: grid;
    gap: 0.7rem;
}

.themelogik-history .themelogik-history-card__body {
    display: grid;
    gap: 0.8rem;
    width: min(100%, 33rem);
}

.themelogik-history .themelogik-history-card__eyebrow {
    font-size: 0.88rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    opacity: 0.84;
}

.themelogik-history .themelogik-history-card__page-title {
    font-size: clamp(2.35rem, 4.7vw, 4.5rem);
    line-height: 0.98;
}

.themelogik-history .themelogik-history-card__page-intro {
    width: min(100%, 35rem);
    font-size: clamp(1rem, 1.6vw, 1.2rem);
    line-height: 1.7;
}

.themelogik-history .themelogik-history-card__page-intro > * {
    margin: 0;
}

.themelogik-history .themelogik-history-card__title {
    font-size: clamp(1.2rem, 2vw, 1.65rem);
    line-height: 1.18;
}

.themelogik-history .themelogik-history-card__text {
    font-size: clamp(0.98rem, 1.35vw, 1.08rem);
    line-height: 1.6;
    opacity: 0.94;
}

.themelogik-history .themelogik-history-card__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 100%;
    padding: 0.85rem 1.4rem;
    border: 1px solid currentColor;
    border-radius: 999px;
    background: color-mix(in srgb, var(--wp--preset--color--white, #fff) 12%, transparent);
    color: var(--wp--preset--color--white, #fff);
    text-align: center;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.themelogik-history .themelogik-history-card:hover .themelogik-history-card__cta,
.themelogik-history .themelogik-history-card:focus-visible .themelogik-history-card__cta {
    background: var(--wp--preset--color--white, currentColor);
    color: var(--wp--preset--color--black, inherit);
    transform: translateY(-1px);
}

.themelogik-history-modal {
    position: fixed;
    inset: 0;
    z-index: 1085;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1rem, 4vw, 2rem);
    box-sizing: border-box;
}

.themelogik-history-modal[hidden] {
    display: none;
}

.themelogik-history-modal__backdrop {
    position: absolute;
    inset: 0;
    background: color-mix(in srgb, var(--wp--preset--color--black, #000) 56%, transparent);
}

.themelogik-history-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 46rem);
    max-height: min(100vh - 2rem, 46rem);
    overflow: auto;
    padding: clamp(1.5rem, 4vw, 2.4rem);
    border-radius: 1.75rem;
    background: color-mix(in srgb, var(--wp--preset--color--white, #fff) 94%, transparent);
    box-shadow: 0 24px 64px color-mix(in srgb, var(--wp--preset--color--black, #000) 18%, transparent);
    box-sizing: border-box;
}

.themelogik-history-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1.1rem;
    border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--black, #000) 10%, transparent);
}

.themelogik-history-modal__heading {
    display: grid;
    gap: 0.35rem;
    min-width: 0;
}

.themelogik-history-modal__close {
    appearance: none;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.65rem;
    height: 2.65rem;
    border: 1px solid color-mix(in srgb, var(--wp--preset--color--black, #000) 10%, transparent);
    border-radius: 999px;
    background: color-mix(in srgb, var(--wp--preset--color--white, #fff) 65%, var(--wp--preset--color--black, #000) 4%);
    color: inherit;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.themelogik-history-modal__close:hover,
.themelogik-history-modal__close:focus-visible {
    background: color-mix(in srgb, var(--wp--preset--color--white, #fff) 40%, var(--wp--preset--color--black, #000) 8%);
    transform: translateY(-1px);
}

.themelogik-history-modal__close:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.themelogik-history-modal__title,
.themelogik-history-modal__subtitle,
.themelogik-history-modal__content > * {
    margin: 0;
}

.themelogik-history-modal__title {
    font-size: clamp(2rem, 3.6vw, 2.9rem);
    line-height: 0.98;
}

.themelogik-history-modal__subtitle {
    font-size: clamp(1rem, 1.5vw, 1.12rem);
    line-height: 1.5;
    opacity: 0.72;
}

.themelogik-history-modal__content {
    margin-top: 1.3rem;
    display: grid;
    gap: 1.1rem;
    line-height: 1.78;
}

.themelogik-history-modal__content p + p {
    margin-top: 0.15rem;
}

body.themelogik-history-modal-open {
    overflow: hidden;
}

@media (max-width: 899px) {
    .themelogik-history {
        padding-top: clamp(5.2rem, 18vw, 6.2rem);
    }

    .themelogik-history .themelogik-history-card {
        width: min(100%, 1000px);
        min-height: 24rem;
    }

    .themelogik-history .themelogik-history-card__page-title {
        font-size: clamp(2rem, 5.2vw, 3.2rem);
    }
}

@media (max-width: 640px) {
    .themelogik-history .themelogik-history__inner {
        padding-inline: 1rem;
    }

    .themelogik-history .themelogik-history-card {
        width: 100%;
        min-height: 22rem;
        padding: 1.25rem;
        border-radius: 1.25rem;
    }

    .themelogik-history .themelogik-history-card__content {
        width: 100%;
        gap: 1rem;
    }

    .themelogik-history .themelogik-history-card__page-title {
        font-size: clamp(1.85rem, 8vw, 2.5rem);
    }

    .themelogik-history .themelogik-history-card__page-intro {
        width: 100%;
        font-size: 1rem;
    }

    .themelogik-history-modal {
        padding: 0.75rem;
    }

    .themelogik-history-modal__dialog {
        max-height: min(100vh - 1.5rem, 42rem);
        padding: 1.25rem;
        border-radius: 1.2rem;
    }

    .themelogik-history-modal__header {
        gap: 0.75rem;
        padding-bottom: 0.95rem;
    }

    .themelogik-history-modal__close {
        width: 2.4rem;
        height: 2.4rem;
    }
}

.themelogik-history {
    background-color: color-mix(in srgb, var(--color-principal, #FCFCFC) 88%, var(--color-secundario, #54595F) 12%);
}

.themelogik-history .themelogik-history-card__page-title,
.themelogik-history .themelogik-history-card__title,
.themelogik-history-modal__title {
    font-family: var(--font-principal-family, "Roboto", sans-serif);
    font-weight: var(--font-principal-weight, 600);
}

.themelogik-history .themelogik-history-card__eyebrow {
    color: var(--color-enfasis, #BF9738);
    font-family: var(--font-enfasis-family, "Roboto", sans-serif);
    font-weight: var(--font-enfasis-weight, 500);
}

.themelogik-history .themelogik-history-card__page-intro,
.themelogik-history .themelogik-history-card__text,
.themelogik-history-modal__content {
    font-family: var(--font-texto-family, "Roboto", sans-serif);
    font-weight: var(--font-texto-weight, 400);
}

.themelogik-history-modal__subtitle {
    color: var(--color-secundario, #54595F);
    font-family: var(--font-secundario-family, "Roboto Slab", serif);
    font-weight: var(--font-secundario-weight, 400);
}

.themelogik-history .themelogik-history-card__cta {
    border-color: var(--color-enfasis, #BF9738);
    color: var(--color-principal, #FCFCFC);
    background: color-mix(in srgb, var(--color-enfasis, #BF9738) 24%, transparent);
    font-family: var(--font-enfasis-family, "Roboto", sans-serif);
    font-weight: var(--font-enfasis-weight, 500);
}

.themelogik-history .themelogik-history-card:hover .themelogik-history-card__cta,
.themelogik-history .themelogik-history-card:focus-visible .themelogik-history-card__cta {
    background: var(--color-principal, #FCFCFC);
    color: var(--color-enfasis, #BF9738);
}
