/**
 * MW Google Reviews: ringkasan rating + kartu ulasan Google Maps.
 * Memakai token tema (--mw-*) dengan fallback agar tetap rapi di tema turunan.
 */

.elementor-widget-mw_google_reviews {
    padding-top: var(--mw-widget-space-y, 0px);
    padding-bottom: var(--mw-widget-space-y, 0px);
}

.mwe-gr {
    --mwe-gr-blue: #4285f4;
    --mwe-gr-red: #ea4335;
    --mwe-gr-yellow: #fbbc04;
    --mwe-gr-green: #34a853;
    --mwe-gr-ink: var(--mw-dark, #0f172a);
    --mwe-gr-body: var(--mw-text, #334155);
    --mwe-gr-muted: var(--mw-muted, #5f6368);
    --mwe-gr-line: var(--mw-border, #e2e8f0);
    --mwe-gr-card: #ffffff;
    --mwe-gr-soft: #f8fafc;
    --mwe-gr-star: var(--mwe-gr-yellow);
    --mwe-gr-star-off: #dadce0;
    --mwe-gr-radius: 18px;
    color: var(--mwe-gr-body);
    font-size: 15px;
    line-height: 1.7;
}

.mwe-gr *,
.mwe-gr *::before,
.mwe-gr *::after {
    box-sizing: border-box;
}

.mwe-gr a:focus-visible,
.mwe-gr button:focus-visible {
    outline: 2px solid var(--mwe-gr-blue);
    outline-offset: 2px;
    border-radius: 6px;
}

.mwe-gr__title {
    margin: 0 0 18px;
    color: var(--mwe-gr-ink);
    font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.6rem);
    line-height: 1.3;
}

.mwe-gr__g {
    display: block;
    flex: 0 0 auto;
}

/* ------------------------------------------------------------------
   Header: identitas Google + ringkasan rating + CTA Maps
   ------------------------------------------------------------------ */

.mwe-gr__head {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px 30px;
    padding: 24px 24px 22px;
    overflow: hidden;
    border: 1px solid var(--mwe-gr-line);
    border-radius: 22px;
    background:
        radial-gradient(120% 150% at 0% 0%, rgba(66, 133, 244, 0.10), transparent 58%),
        radial-gradient(110% 140% at 100% 0%, rgba(234, 67, 53, 0.07), transparent 55%),
        radial-gradient(120% 140% at 50% 100%, rgba(52, 168, 83, 0.06), transparent 60%),
        var(--mwe-gr-card);
    box-shadow: 0 12px 34px rgba(15, 23, 42, 0.06);
}

/* Garis aksen empat warna Google. */
.mwe-gr__head::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 4px;
    background: linear-gradient(
        90deg,
        var(--mwe-gr-blue) 0 25%,
        var(--mwe-gr-red) 25% 50%,
        var(--mwe-gr-yellow) 50% 75%,
        var(--mwe-gr-green) 75% 100%
    );
}

.mwe-gr__identity {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.mwe-gr__brand-mark {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border: 1px solid var(--mwe-gr-line);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.mwe-gr__brand-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    line-height: 1.35;
}

.mwe-gr__brand-title {
    color: var(--mwe-gr-ink);
    font-size: 15.5px;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.mwe-gr__brand-place {
    overflow: hidden;
    max-width: 260px;
    color: var(--mwe-gr-muted);
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mwe-gr__summary {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-left: 28px;
    border-left: 1px solid var(--mwe-gr-line);
}

.mwe-gr__value {
    color: var(--mwe-gr-ink);
    font-size: clamp(2.2rem, 1.8rem + 1.1vw, 2.8rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
}

.mwe-gr__summary-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mwe-gr__stars {
    display: inline-flex;
    gap: 2px;
    color: var(--mwe-gr-star-off);
    line-height: 0;
}

.mwe-gr__star {
    display: block;
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.mwe-gr__star.is-on {
    color: var(--mwe-gr-star);
}

.mwe-gr__count {
    color: var(--mwe-gr-muted);
    font-size: 13.5px;
    line-height: 1.4;
}

.mwe-gr__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    margin-left: auto;
    min-width: 0;
}

.mwe-gr__place {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    max-width: 300px;
    color: var(--mwe-gr-muted);
    font-size: 13px;
    line-height: 1.45;
    text-align: right;
}

.mwe-gr__place-ico {
    flex: 0 0 auto;
    fill: currentColor;
    opacity: 0.75;
}

.mwe-gr__maps {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 18px;
    border-radius: 999px;
    background: var(--mwe-gr-blue);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(66, 133, 244, 0.28);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.mwe-gr__maps:hover,
.mwe-gr__maps:focus {
    background: #1a73e8;
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 12px 26px rgba(66, 133, 244, 0.34);
}

.mwe-gr__maps-ico {
    flex: 0 0 auto;
    fill: currentColor;
}

/* ------------------------------------------------------------------
   Daftar kartu ulasan
   ------------------------------------------------------------------ */

.mwe-gr__list {
    display: grid;
    grid-template-columns: repeat(var(--mwe-gr-cols, 3), minmax(0, 1fr));
    gap: 20px;
    margin-top: 24px;
}

.mwe-gr__card {
    --mwe-gr-accent: var(--mwe-gr-blue);
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow: hidden;
    padding: 22px;
    border: 1px solid var(--mwe-gr-line);
    border-radius: var(--mwe-gr-radius);
    background: var(--mwe-gr-card);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

/* Glow halus di sudut kanan atas per kartu. */
.mwe-gr__card::before {
    content: "";
    position: absolute;
    top: -46px;
    right: -46px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--mwe-gr-accent);
    opacity: 0.08;
    pointer-events: none;
}

/* Strip aksen kiri. */
.mwe-gr__card::after {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: var(--mwe-gr-accent);
    opacity: 0.55;
    transition: opacity 0.2s ease;
}

.mwe-gr__card:hover {
    border-color: rgba(66, 133, 244, 0.4);
    transform: translateY(-3px);
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.10);
}

.mwe-gr__card:hover::after {
    opacity: 1;
}

.mwe-gr__card:nth-child(4n + 2) {
    --mwe-gr-accent: var(--mwe-gr-red);
}

.mwe-gr__card:nth-child(4n + 3) {
    --mwe-gr-accent: var(--mwe-gr-yellow);
}

.mwe-gr__card:nth-child(4n + 4) {
    --mwe-gr-accent: var(--mwe-gr-green);
}

.mwe-gr__card-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mwe-gr__avatar {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

.mwe-gr__avatar--initials {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d2e3fc;
    background: #eef4ff;
    color: #1a73e8;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.mwe-gr__card:nth-child(4n + 2) .mwe-gr__avatar--initials {
    border-color: #fad2cf;
    background: #fce8e6;
    color: #c5221f;
}

.mwe-gr__card:nth-child(4n + 3) .mwe-gr__avatar--initials {
    border-color: #fde293;
    background: #fef7e0;
    color: #b06000;
}

.mwe-gr__card:nth-child(4n + 4) .mwe-gr__avatar--initials {
    border-color: #ceead6;
    background: #e6f4ea;
    color: #137333;
}

.mwe-gr__who {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.mwe-gr__name {
    overflow: hidden;
    color: var(--mwe-gr-ink);
    font-size: 14.5px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

a.mwe-gr__name:hover,
a.mwe-gr__name:focus {
    color: var(--mwe-gr-blue);
    text-decoration: none;
}

.mwe-gr__meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
}

.mwe-gr__card .mwe-gr__star {
    width: 14px;
    height: 14px;
}

.mwe-gr__date {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--mwe-gr-muted);
    font-size: 12.5px;
    line-height: 1.4;
}

.mwe-gr__date-ico {
    flex: 0 0 auto;
    fill: currentColor;
    opacity: 0.7;
}

.mwe-gr__rating-pill {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    padding: 4px 9px;
    border: 1px solid var(--mwe-gr-line);
    border-radius: 999px;
    background: var(--mwe-gr-soft);
    color: var(--mwe-gr-ink);
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.2;
}

.mwe-gr__pill-star {
    flex: 0 0 auto;
    fill: var(--mwe-gr-star);
}

.mwe-gr__text {
    display: -webkit-box;
    overflow: hidden;
    margin: 0;
    color: var(--mwe-gr-body);
    font-size: 14.5px;
    line-height: 1.68;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 6;
}

.mwe-gr__card-foot {
    display: flex;
    justify-content: flex-end;
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px dashed var(--mwe-gr-line);
}

.mwe-gr__perma {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--mw-primary, #1a73e8);
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}

.mwe-gr__perma:hover,
.mwe-gr__perma:focus {
    color: var(--mw-primary, #1a73e8);
    text-decoration: none;
    opacity: 0.85;
}

.mwe-gr__link-ico {
    flex: 0 0 auto;
    fill: currentColor;
    transition: transform 0.18s ease;
}

.mwe-gr__perma:hover .mwe-gr__link-ico,
.mwe-gr__attr-link:hover .mwe-gr__link-ico {
    transform: translate(1px, -1px);
}

.mwe-gr__source {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--mwe-gr-muted);
    font-size: 12.5px;
    font-weight: 600;
}

/* ------------------------------------------------------------------
   Slider horizontal
   ------------------------------------------------------------------ */

.mwe-gr--slider .mwe-gr__list {
    display: flex;
    overflow-x: auto;
    padding: 4px 2px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
}

.mwe-gr--slider .mwe-gr__list::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.mwe-gr--slider .mwe-gr__card {
    flex: 0 0 min(340px, 86%);
}

/* Navigasi slider: panah + dot (tanpa scrollbar). */
.mwe-gr__nav {
    display: none;
    align-items: center;
    gap: 14px;
    margin-top: 16px;
}

.mwe-gr__slider.is-ready .mwe-gr__nav {
    display: flex;
}

.mwe-gr__slider--static .mwe-gr__nav {
    display: none;
}

.mwe-gr__nav-btn {
    display: grid;
    flex: 0 0 auto;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 1px solid var(--mwe-gr-line);
    border-radius: 50%;
    background: #fff;
    color: var(--mwe-gr-ink);
    cursor: pointer;
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, opacity 0.18s ease;
}

.mwe-gr__nav-btn:hover:not(:disabled),
.mwe-gr__nav-btn:focus-visible:not(:disabled) {
    border-color: var(--mwe-gr-blue);
    background: var(--mwe-gr-blue);
    color: #fff;
}

.mwe-gr__nav-btn:disabled {
    opacity: 0.35;
    cursor: default;
}

.mwe-gr__nav-ico {
    fill: currentColor;
}

.mwe-gr__dots {
    display: flex;
    flex: 1 1 auto;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.mwe-gr__dot {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: var(--mwe-gr-star-off);
    cursor: pointer;
    transition: width 0.2s ease, background-color 0.2s ease;
}

.mwe-gr__dot:hover,
.mwe-gr__dot:focus-visible {
    background: var(--mwe-gr-muted);
}

.mwe-gr__dot.is-active {
    width: 24px;
    background: var(--mwe-gr-blue);
}

/* ------------------------------------------------------------------
   Layout ringkasan saja
   ------------------------------------------------------------------ */

.mwe-gr--summary .mwe-gr__head {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 32px 24px;
    text-align: center;
}

.mwe-gr--summary .mwe-gr__summary {
    flex-direction: column;
    gap: 10px;
    padding-left: 0;
    border-left: 0;
}

.mwe-gr--summary .mwe-gr__summary-meta {
    align-items: center;
}

.mwe-gr--summary .mwe-gr__value {
    font-size: clamp(2.8rem, 2.2rem + 2vw, 3.8rem);
}

.mwe-gr--summary .mwe-gr__actions {
    align-items: center;
    margin-left: 0;
}

.mwe-gr--summary .mwe-gr__place {
    max-width: 420px;
    text-align: center;
}

/* ------------------------------------------------------------------
   Atribusi & keadaan kosong
   ------------------------------------------------------------------ */

.mwe-gr__attr {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 8px 16px;
    margin-top: 16px;
    color: var(--mwe-gr-muted);
    font-size: 12.5px;
}

.mwe-gr__attr-note,
.mwe-gr__attr-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.mwe-gr__attr-note {
    font-weight: 500;
}

.mwe-gr__attr-link {
    color: var(--mwe-gr-muted);
    font-weight: 600;
    text-decoration: none;
}

.mwe-gr__attr-link:hover,
.mwe-gr__attr-link:focus {
    color: var(--mwe-gr-ink);
    text-decoration: none;
}

.mwe-gr__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 26px 20px;
    border: 1px dashed var(--mwe-gr-line);
    border-radius: var(--mwe-gr-radius);
    background: var(--mwe-gr-soft);
    color: var(--mwe-gr-muted);
    text-align: center;
}

.mwe-gr__empty-mark {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--mwe-gr-line);
    border-radius: 50%;
    background: #fff;
}

.mwe-gr__empty p {
    margin: 0;
}

/* ------------------------------------------------------------------
   Responsif
   ------------------------------------------------------------------ */

@media (max-width: 1024px) {
    .mwe-gr__head {
        gap: 16px 22px;
    }

    .mwe-gr__summary {
        padding-left: 20px;
    }

    .mwe-gr__list {
        grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    }
}

@media (max-width: 900px) {
    .mwe-gr__head {
        flex-direction: column;
        align-items: flex-start;
    }

    .mwe-gr__summary {
        padding-left: 0;
        border-left: 0;
    }

    .mwe-gr__actions {
        align-items: flex-start;
        margin-left: 0;
    }

    .mwe-gr__place {
        max-width: 100%;
        text-align: left;
    }
}

@media (max-width: 640px) {
    .mwe-gr__head {
        padding: 20px 18px;
        border-radius: 18px;
    }

    .mwe-gr__list {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
    }

    .mwe-gr__card {
        padding: 18px;
    }

    .mwe-gr__maps {
        width: 100%;
        justify-content: center;
    }

    .mwe-gr--summary .mwe-gr__maps {
        width: auto;
    }

    .mwe-gr__attr {
        justify-content: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mwe-gr__card,
    .mwe-gr__maps,
    .mwe-gr__link-ico {
        transition: none;
    }

    .mwe-gr__card:hover,
    .mwe-gr__maps:hover {
        transform: none;
    }
}
