/**
 * Showroom 360 — port từ Reference/style.css
 * Block: .tgw-s360 (tgwv-builder-showroom360)
 */

.tgw-s360 {
    --tgw-s360-ease: cubic-bezier(0.4, 0, 0.2, 1);
    --tgw-s360-duration: 0.3s;
    --tgw-s360-bg: #f7f7f7;
    --tgw-s360-title-color: #201c1c;
    --tgw-s360-desc-color: #696969;
    --tgw-s360-link-color: #374586;
    --tgw-s360-link-hover-color: #283c85;
    --tgw-s360-card-media-ratio: 4 / 3;

    width: 100%;
    box-sizing: border-box;
    background-color: var(--tgw-s360-bg);
    padding: 52px 0;
}

.tgw-s360__container {
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px;
    padding-right: 15px;
    box-sizing: border-box;
}

@media (min-width: 992px) and (max-width: 1199.98px) {
    .tgw-s360__container {
        padding-left: 12px;
        padding-right: 12px;
    }
}

@media (max-width: 991.98px) {
    .tgw-s360__container {
        padding-left: 10px;
        padding-right: 10px;
    }
}

.tgw-s360__header {
    margin-bottom: 28px;
}

.tgw-s360__title {
    color: var(--tgw-s360-title-color);
    margin: 0 0 12px;
    font-size: clamp(1.65rem, 2.6vw, 2rem);
    font-weight: 700;
}

.tgw-s360__intro {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.tgw-s360__desc {
    margin: 0;
    color: var(--tgw-s360-desc-color);
    font-size: 15px;
    line-height: 1.6;
    max-width: 680px;
}

.tgw-s360__link {
    color: var(--tgw-s360-link-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    transition: color var(--tgw-s360-duration) var(--tgw-s360-ease);
}

.tgw-s360__link i {
    font-size: 12px;
}

.tgw-s360__link:hover {
    color: var(--tgw-s360-link-hover-color);
}

.tgw-s360__link:focus-visible {
    outline: 2px solid var(--tgw-s360-link-hover-color);
    outline-offset: 3px;
    border-radius: 4px;
}

.tgw-s360-card {
    background-color: #fff;
    border-radius: 14px;
    overflow: hidden;
    height: 100%;
    box-shadow: 0 4px 20px rgba(20, 16, 15, 0.05);
    transition:
        transform 0.35s var(--tgw-s360-ease),
        box-shadow 0.35s var(--tgw-s360-ease);
}

.tgw-s360-card__media {
    aspect-ratio: var(--tgw-s360-card-media-ratio);
    overflow: hidden;
}

.tgw-s360-card__media-link {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.tgw-s360-card__media-link:focus-visible {
    outline: 2px solid var(--tgw-s360-link-color);
    outline-offset: -2px;
}

.tgw-s360-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.45s var(--tgw-s360-ease);
}

.tgw-s360-card__body {
    padding: 18px 16px 20px;
}

.tgw-s360-card__title {
    margin: 0 0 8px;
    font-size: clamp(1.45rem, 2.2vw, 1.5rem);
    line-height: 1.2;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
}

.tgw-s360-card__title-link {
    color: #222;
    text-decoration: none !important;
    font: inherit;
    font-weight: 700;
    line-height: inherit;
    transition: color var(--tgw-s360-duration) var(--tgw-s360-ease);
}

.tgw-s360-card__title-link:focus-visible {
    outline: 2px solid var(--tgw-s360-link-color);
    outline-offset: 2px;
    border-radius: 2px;
}

.tgw-s360-card__desc {
    margin: 0;
    color: #707070;
    font-size: 13px;
    line-height: 1.5;
}

@media (hover: hover) and (pointer: fine) {
    .tgw-s360:not(.tgw-s360--no-hover) .tgw-s360-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 14px 36px rgba(20, 16, 15, 0.12);
    }

    .tgw-s360:not(.tgw-s360--no-hover) .tgw-s360-card:hover .tgw-s360-card__image {
        transform: scale(1.05);
    }

    .tgw-s360:not(.tgw-s360--no-hover) .tgw-s360-card__title-link:hover {
        color: var(--tgw-s360-link-color);
        text-decoration: underline;
        text-underline-offset: 3px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tgw-s360-card,
    .tgw-s360-card__image,
    .tgw-s360__link {
        transition: none;
    }

    @media (hover: hover) and (pointer: fine) {
        .tgw-s360:not(.tgw-s360--no-hover) .tgw-s360-card:hover {
            transform: none;
        }

        .tgw-s360:not(.tgw-s360--no-hover) .tgw-s360-card:hover .tgw-s360-card__image {
            transform: none;
        }
    }
}

@media (max-width: 991.98px) {
    .tgw-s360 {
        padding: 42px 0;
    }
}

@media (max-width: 767.98px) {
    .tgw-s360__intro {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 575.98px) {
    .tgw-s360 {
        padding: 34px 0;
    }
}
