/*============================================

   ThemeAdapt — home hero, bento design

   Headline and search on the left, a grid of live catalogue tiles on the
   right. Loaded only on the days this design is on show; the shared hero
   pieces (badge, title, search) live in themeadapt-marketplace.css.

==============================================*/

/* Not clipped, like the base hero: the category list has to hang past the
   bottom edge. Everything decorative below stays inside `inset: 0`. */
.ta-hero--bento {
    padding-block: clamp(56px, 4vw + 34px, 84px) clamp(64px, 4vw + 40px, 96px);
    background: var(--ta-background);
}

/* The wash moves left, behind the headline, with a second one under the grid. */
.ta-hero--bento::after {
    background:
        radial-gradient(560px 420px at 14% 22%, color-mix(in srgb, var(--ta-accent) 11%, transparent), transparent 70%),
        radial-gradient(640px 520px at 88% 70%, color-mix(in srgb, var(--ta-accent) 7%, transparent), transparent 70%);
}

/* Faint grid, fading out from the middle. */
.ta-hero--bento::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: .5;
    background-image:
        linear-gradient(#222 1px, transparent 1px),
        linear-gradient(90deg, #222 1px, transparent 1px);
    background-size: 64px 64px;
    -webkit-mask-image: radial-gradient(900px 500px at 50% 40%, #000, transparent 75%);
    mask-image: radial-gradient(900px 500px at 50% 40%, #000, transparent 75%);
    pointer-events: none;
}

.ta-hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr);
    gap: 56px;
    align-items: center;
}

.ta-hero--bento .ta-hero__title {
    margin-bottom: 22px;
    font-size: clamp(2.5rem, 1.6rem + 2.6vw, 4rem);
}

.ta-hero--bento .ta-hero__accent {
    display: inline-block;
}

.ta-hero--bento .ta-hero__text {
    max-width: 500px;
    margin-inline: 0;
    margin-bottom: 30px;
}

.ta-hero--bento .ta-search {
    max-width: none;
    margin-inline: 0;
}

.ta-hero--bento .ta-search__tags {
    justify-content: flex-start;
    margin-top: 18px;
}

.ta-hero__trust {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    margin: 28px 0 0;
    padding: 22px 0 0;
    border-top: 1px dashed var(--ta-border);
    list-style: none;
    font-size: .875rem;
    font-weight: var(--ta-fw-medium);
    color: #cfcfcf;
}

.ta-hero__trust li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ta-hero__trust svg {
    width: 16px;
    height: 16px;
    color: var(--ta-accent);
}

/* -------------------------------------------------------------------------
 * The grid
 * ---------------------------------------------------------------------- */

.ta-bento {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: 172px 150px 152px;
    gap: 14px;
}

.ta-bento__cell {
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 18px;
    border: 1px solid #2c2c2c;
    border-radius: 22px;
    background: linear-gradient(180deg, #1f1f1f, #1a1a1a);
    color: var(--ta-foreground);
    transition: border-color .2s ease, transform .3s var(--ta-ease);
}

a.ta-bento__cell:hover {
    border-color: color-mix(in srgb, var(--ta-accent) 55%, transparent);
    transform: translateY(-2px);
}

.ta-bento__eyebrow {
    font-size: .6875rem;
    font-weight: var(--ta-fw-bold);
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #8d8d8d;
}

.ta-bento__cell b {
    font-family: var(--ta-font-head);
    font-weight: var(--ta-fw-bold);
    letter-spacing: -.02em;
}

/* This week's pick: two rows, two columns. */
.ta-bento__feat {
    grid-column: 1 / 3;
    grid-row: 1 / 3;
    padding: 8px;
}

.ta-bento__shot {
    position: relative;
    flex: none;
    height: 222px;
    overflow: hidden;
    border-radius: 15px;
    background: var(--ta-surface-2);
}

.ta-bento__shot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top left;
    transition: transform .6s var(--ta-ease);
}

.ta-bento__feat:hover .ta-bento__shot img {
    transform: scale(1.03);
}

.ta-bento__chip {
    position: absolute;
    top: 12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 11px;
    border-radius: var(--ta-radius-pill);
    background: rgba(15, 15, 15, .82);
    backdrop-filter: blur(6px);
    font-size: .75rem;
    font-weight: var(--ta-fw-bold);
    color: var(--ta-accent);
}

.ta-bento__chip svg {
    width: 14px;
    height: 14px;
}

.ta-bento__info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0 10px 0 12px;
}

.ta-bento__name {
    flex: 1;
    min-width: 0;
}

.ta-bento__name b {
    display: -webkit-box;
    margin-top: 5px;
    overflow: hidden;
    font-size: 1.0625rem;
    line-height: 1.25;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ta-bento__price {
    flex: none;
    text-align: right;
}

.ta-bento__price b {
    display: block;
    font-size: 1.5rem;
    letter-spacing: -.03em;
}

.ta-bento__price small,
.ta-bento__price del {
    display: block;
    font-size: .75rem;
    color: #8d8d8d;
}

.ta-bento__go {
    flex: none;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid #383838;
    border-radius: 50%;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.ta-bento__go svg {
    width: 16px;
    height: 16px;
}

.ta-bento__feat:hover .ta-bento__go {
    border-color: var(--ta-accent);
    background: var(--ta-accent);
    color: var(--ta-cta-fg);
}

/* All Access, in the brand lime. */
.ta-bento__access {
    grid-column: 3;
    grid-row: 1;
    border-color: var(--ta-cta-border);
    background: var(--ta-accent);
    color: #0d1d02;
}

.ta-bento__access .ta-bento__eyebrow {
    color: #2f5a10;
}

.ta-bento__access b {
    margin-top: 8px;
    font-size: 1.25rem;
    line-height: 1.08;
    letter-spacing: -.03em;
}

.ta-bento__access-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
    font-weight: var(--ta-fw-bold);
    font-size: .9375rem;
}

.ta-bento__access-foot del {
    margin-left: 4px;
    font-weight: var(--ta-fw-medium);
    opacity: .6;
}

.ta-bento__access-foot i {
    flex: none;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #0d1d02;
    color: var(--ta-accent);
}

.ta-bento__access-foot svg {
    width: 15px;
    height: 15px;
}

/* Lifetime updates. */
.ta-bento__updates {
    grid-column: 3;
    grid-row: 2;
}

.ta-bento__icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--ta-accent-soft);
    color: var(--ta-accent);
}

.ta-bento__icon svg {
    width: 22px;
    height: 22px;
}

.ta-bento__updates b {
    margin-top: auto;
    font-size: 1.0625rem;
    line-height: 1.1;
}

.ta-bento__updates > span:last-child {
    margin-top: 4px;
    font-size: .75rem;
    color: #8d8d8d;
}

/* The newest release. */
.ta-bento__latest {
    grid-column: 1 / 3;
    grid-row: 3;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 14px;
}

.ta-bento__thumb {
    flex: none;
    width: 200px;
    height: 122px;
    overflow: hidden;
    border-radius: 13px;
    background: var(--ta-surface-2);
}

.ta-bento__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left;
}

.ta-bento__latest-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.ta-bento__latest b {
    margin: 6px 0 2px;
    font-size: 1.0625rem;
}

.ta-bento__kind {
    display: -webkit-box;
    overflow: hidden;
    font-size: .8125rem;
    line-height: 1.4;
    color: #9a9a9a;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ta-bento__fresh {
    align-self: flex-start;
    margin-top: 10px;
    padding: 4px 9px;
    border-radius: var(--ta-radius-pill);
    background: var(--ta-accent-soft);
    font-size: .71875rem;
    font-weight: var(--ta-fw-bold);
    color: var(--ta-accent);
    white-space: nowrap;
}

/* The platforms, each a link to its category. */
/* Label, count and two rows of links have to share 116px, so the lines are
   set tight and the gaps given on purpose rather than left to chance. */
.ta-bento__platforms {
    grid-column: 3;
    grid-row: 3;
    justify-content: center;
    padding: 16px 18px;
}

.ta-bento__platforms .ta-bento__eyebrow {
    line-height: 1.2;
}

.ta-bento__platforms b {
    margin-top: 6px;
    font-size: 1.0625rem;
    line-height: 1.2;
}

.ta-bento__stack {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    margin-top: 12px;
}

.ta-bento__stack a {
    display: grid;
    place-items: center;
    height: 30px;
    border: 1px solid #313131;
    border-radius: 10px;
    background: #262626;
    color: #e6e6e6;
    transition: border-color .2s ease, color .2s ease;
}

.ta-bento__stack a:hover {
    border-color: var(--ta-accent);
    color: var(--ta-accent);
}

.ta-bento__stack svg {
    width: 16px;
    height: 16px;
}

.ta-bento__stack .ta-bento__all {
    border-color: color-mix(in srgb, var(--ta-accent) 40%, transparent);
    background: var(--ta-accent-soft);
    color: var(--ta-accent);
}

/* -------------------------------------------------------------------------
 * Smaller screens
 * ---------------------------------------------------------------------- */

@media (max-width: 1099px) {
    .ta-hero__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 48px;
    }

    .ta-hero--bento .ta-hero__text {
        max-width: 620px;
    }
}

@media (max-width: 767px) {
    .ta-hero--bento {
        padding-block: 44px 40px;
    }
}

@media (max-width: 640px) {
    .ta-bento {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: none;
        grid-auto-rows: auto;
    }

    .ta-bento__feat,
    .ta-bento__latest {
        grid-column: 1 / -1;
        grid-row: auto;
    }

    .ta-bento__access,
    .ta-bento__updates,
    .ta-bento__platforms {
        grid-column: auto;
        grid-row: auto;
        min-height: 150px;
    }

    .ta-bento__platforms {
        grid-column: 1 / -1;
    }

    .ta-bento__shot {
        height: auto;
        aspect-ratio: 856 / 434;
    }

    .ta-bento__info {
        padding: 14px 6px 8px 8px;
    }

    .ta-bento__thumb {
        width: 42%;
        height: auto;
        aspect-ratio: 856 / 520;
    }

    .ta-bento__stack {
        grid-template-columns: repeat(6, minmax(0, 1fr));
        margin-top: 16px;
    }
}
