.tmti-wrap,
.tmti-wrap * {
    box-sizing: border-box;
}

.tmti-wrap {
    --tmti-rose: #c99191;
    --tmti-rose-dark: #9f6f75;
    --tmti-blush: #fde3da;
    --tmti-cream: #fbf5f1;
    --tmti-cream-deep: #f4ebe5;
    --tmti-ink: #3c3335;
    --tmti-muted: #7d7071;
    --tmti-border: rgba(201, 145, 145, .27);
    width: 100%;
    color: var(--tmti-ink);
    font-family: inherit;
}

.tmti-heading {
    max-width: 790px;
    margin: 0 auto 30px;
    text-align: center;
}

.tmti-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    margin-bottom: 12px;
    padding: 6px 16px;
    border: 1px solid var(--tmti-border);
    border-radius: 999px;
    background: linear-gradient(135deg, #fff, var(--tmti-cream));
    color: var(--tmti-rose-dark);
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 8px 25px rgba(169, 111, 118, .08);
}

.tmti-heading h2 {
    margin: 0 0 10px;
    color: var(--tmti-ink);
    font-size: clamp(27px, 3.2vw, 42px);
    line-height: 1.5;
    font-weight: 900;
}

.tmti-heading p {
    margin: 0;
    color: var(--tmti-muted);
    font-size: 15px;
    line-height: 2;
}

.tmti-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 9px;
    margin: 0 auto 28px;
}

.tmti-filter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 45px;
    padding: 9px 15px 9px 10px;
    border: 1px solid var(--tmti-border);
    border-radius: 999px;
    background: #fff;
    color: var(--tmti-ink);
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 7px 22px rgba(68, 48, 51, .045);
    transition: transform .2s ease, background-color .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.tmti-filter b {
    display: grid;
    min-width: 25px;
    height: 25px;
    place-items: center;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--tmti-cream);
    color: var(--tmti-rose-dark);
    font-size: 10px;
    line-height: 1;
    transition: inherit;
}

.tmti-filter:hover {
    transform: translateY(-1px);
    border-color: var(--tmti-rose);
    box-shadow: 0 10px 27px rgba(169, 111, 118, .11);
}

.tmti-filter.is-active {
    border-color: var(--tmti-rose);
    background: var(--tmti-rose);
    color: #fff;
    box-shadow: 0 11px 28px rgba(169, 111, 118, .23);
}

.tmti-filter.is-active b {
    background: rgba(255, 255, 255, .23);
    color: #fff;
}

.tmti-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 19px;
}

.tmti-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(169, 111, 118, .13);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 12px 35px rgba(68, 48, 51, .075);
    transition: transform .28s ease, box-shadow .28s ease, opacity .2s ease;
}

.tmti-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 19px 48px rgba(68, 48, 51, .13);
}

.tmti-card.is-hidden {
    display: none;
}

.tmti-image-button {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

.tmti-image-frame {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--tmti-cream);
}

.tmti-image-frame img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform .48s ease, filter .3s ease;
}

.tmti-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    background: linear-gradient(180deg, rgba(55, 39, 42, .04), rgba(55, 39, 42, .54));
    color: #fff;
    opacity: 0;
    transition: opacity .25s ease;
}

.tmti-overlay i {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border: 1px solid rgba(255,255,255,.52);
    border-radius: 50%;
    background: rgba(255,255,255,.16);
    font-style: normal;
    font-size: 25px;
    backdrop-filter: blur(8px);
}

.tmti-overlay em {
    font-style: normal;
    font-size: 11px;
    font-weight: 800;
}

.tmti-card:hover .tmti-image-frame img {
    transform: scale(1.045);
}

.tmti-card:hover .tmti-overlay,
.tmti-image-button:focus-visible .tmti-overlay {
    opacity: 1;
}

.tmti-card-body {
    min-height: 116px;
    padding: 15px 16px 18px;
    text-align: right;
}

.tmti-category-badge {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 5px 9px;
    border-radius: 999px;
    background: var(--tmti-blush);
    color: var(--tmti-rose-dark);
    font-size: 10px;
    font-weight: 900;
}

.tmti-card-body h3 {
    margin: 0;
    color: var(--tmti-ink);
    font-size: 14px;
    line-height: 1.8;
    font-weight: 900;
}

.tmti-card-body p {
    display: -webkit-box;
    overflow: hidden;
    margin: 6px 0 0;
    color: var(--tmti-muted);
    font-size: 12px;
    line-height: 1.8;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tmti-empty {
    margin-top: 22px;
    padding: 27px;
    border: 1px dashed var(--tmti-border);
    border-radius: 19px;
    background: var(--tmti-cream);
    color: var(--tmti-muted);
    text-align: center;
}

.tmti-lightbox[hidden] {
    display: none;
}

.tmti-lightbox {
    position: fixed;
    z-index: 999999;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 28px;
    background: rgba(31, 24, 25, .88);
    backdrop-filter: blur(8px);
}

.tmti-lightbox-inner {
    display: flex;
    width: min(94vw, 1050px);
    max-height: 89vh;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.tmti-lightbox img {
    display: block;
    max-width: 100%;
    max-height: calc(89vh - 58px);
    border-radius: 18px;
    object-fit: contain;
    box-shadow: 0 25px 75px rgba(0, 0, 0, .39);
}

.tmti-lightbox p {
    margin: 0;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
}

.tmti-lightbox-close {
    position: fixed;
    top: 18px;
    left: 18px;
    display: grid;
    width: 47px;
    height: 47px;
    place-items: center;
    padding: 0;
    border: 1px solid rgba(255,255,255,.36);
    border-radius: 50%;
    background: rgba(255,255,255,.13);
    color: #fff;
    font: inherit;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
}

body.tmti-lightbox-open {
    overflow: hidden;
}

@media (max-width: 1080px) {
    .tmti-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .tmti-heading {
        margin-bottom: 23px;
    }

    .tmti-heading h2 {
        font-size: 27px;
    }

    .tmti-heading p {
        font-size: 13px;
        line-height: 1.9;
    }

    .tmti-filters {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 18px;
    }

    .tmti-filter {
        width: 100%;
        min-height: 43px;
        padding: 8px 10px;
        font-size: 11px;
    }

    .tmti-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .tmti-card {
        border-radius: 15px;
    }

    .tmti-card-body {
        min-height: 96px;
        padding: 10px 10px 12px;
    }

    .tmti-category-badge {
        margin-bottom: 6px;
        padding: 4px 7px;
        font-size: 8px;
    }

    .tmti-card-body h3 {
        font-size: 10.5px;
        line-height: 1.75;
    }

    .tmti-card-body p {
        font-size: 9px;
    }

    .tmti-overlay {
        display: none;
    }

    .tmti-lightbox {
        padding: 16px;
    }
}

@media (max-width: 370px) {
    .tmti-filters,
    .tmti-grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tmti-card,
    .tmti-filter,
    .tmti-image-frame img,
    .tmti-overlay {
        transition: none;
    }
}
