/* ================================================
   TEAM GLAM — Editorial Client Stories Masonry Widget
   ================================================ */

.tg-cs-wrap {
    width: 100%;
    background-color: #ffffff;
    padding: 100px 40px;
    box-sizing: border-box;
}

.tg-cs-container {
    max-width: 1360px;
    margin: 0 auto;
    width: 100%;
}

/* ── Header ── */
.tg-cs-header {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 40px;
    align-items: end;
    margin-bottom: 64px;
    width: 100%;
}

.tg-cs-heading {
    font-family: 'beaufort-pro', serif;
    font-size: clamp(40px, 5vw, 68px);
    font-weight: 400;
    color: #111111;
    margin: 0;
    line-height: 1.05;
    letter-spacing: -0.01em;
}

body .tg-cs-desc,
.tg-cs-desc {
    font-family: 'brandon-grotesque', sans-serif;
    font-size: var(--tg-body-font-size, 18px) !important;
    line-height: 1.65;
    color: #555555;
    max-width: 580px;
    justify-self: end;
}

/* ── Masonry Grid ── */
.tg-cs-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
    width: 100%;
    align-items: stretch;
}

.tg-cs-span-1 { grid-column: span 1; }
.tg-cs-span-2 { grid-column: span 2; }

/* ── Card Base ── */
.tg-cs-card {
    position: relative;
    background-color: #f7f7f7;
    padding: 48px 36px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    width: 100%;
    min-height: 280px;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.tg-cs-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

/* ── Photo Overlay Card ── */
.tg-cs-card--photo {
    padding: 48px 36px;
    overflow: hidden;
    background-color: #111111;
    min-height: 420px;
    justify-content: flex-end;
}

.tg-cs-photo-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 0;
}

.tg-cs-card--photo:hover .tg-cs-photo-bg {
    transform: scale(1.05);
}

.tg-cs-photo-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.25) 60%, rgba(0, 0, 0, 0.1) 100%);
    z-index: 1;
}

.tg-cs-photo-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
}

/* ── Quote ── */
.tg-cs-quote {
    font-family: 'beaufort-pro', serif;
    font-size: clamp(18px, 1.8vw, 24px);
    font-weight: 400;
    line-height: 1.38;
    color: #111111;
    margin: 0 0 32px;
}

.tg-cs-quote--white {
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* ── Author Meta ── */
.tg-cs-author-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: auto;
}

body .tg-cs-author,
.tg-cs-author {
    font-family: 'brandon-grotesque', sans-serif !important;
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 400;
    color: #222222;
}

.tg-cs-author--white {
    color: #ffffff;
}

.tg-cs-role {
    font-family: 'brandon-grotesque', sans-serif;
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #777777;
}

.tg-cs-role--white {
    color: rgba(255, 255, 255, 0.85);
}

/* ── Rating Stars Card ── */
.tg-cs-card--rating {
    align-items: center;
    text-align: center;
    padding: 60px 48px;
}

.tg-cs-card--rating .tg-cs-quote {
    text-align: center;
}

.tg-cs-card--rating .tg-cs-author-wrap {
    align-items: center;
    text-align: center;
}

.tg-cs-stars {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
    color: #111111;
    justify-content: center;
}

.tg-cs-star-icon {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
    .tg-cs-wrap {
        padding: 72px 24px;
    }
    .tg-cs-header {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-bottom: 44px;
    }
    .tg-cs-desc {
        justify-self: start;
    }
    .tg-cs-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 767px) {
    .tg-cs-wrap {
        padding: 40px 16px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }
    .tg-cs-header {
        display: flex !important;
        flex-direction: column !important;
        gap: 16px !important;
        margin-bottom: 32px !important;
        align-items: flex-start !important;
    }
    .tg-cs-heading {
        font-size: clamp(32px, 8vw, 44px) !important;
        text-align: left !important;
    }
    body .tg-cs-desc,
    .tg-cs-desc {
        font-size: var(--tg-body-font-size, 18px) !important;
        line-height: 1.6 !important;
        color: #555555 !important;
        max-width: 100% !important;
        text-align: left !important;
        justify-self: start !important;
    }
    .tg-cs-grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 24px !important;
        width: 100% !important;
    }
    .tg-cs-span-1, .tg-cs-span-2 {
        grid-column: auto !important;
    }
    .tg-cs-card {
        padding: 40px 24px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        border-radius: 0 !important;
    }
    .tg-cs-card--text {
        min-height: 220px !important;
        background-color: #f7f7f7 !important;
    }
    .tg-cs-card--photo {
        min-height: 480px !important;
        padding: 40px 24px !important;
    }
    .tg-cs-card--rating {
        padding: 48px 24px !important;
        background-color: #ffffff !important;
    }
    .tg-cs-quote {
        font-size: 18px !important;
        line-height: 1.4 !important;
        margin-bottom: 24px !important;
    }
}
