/* Google-arvostelut -plugin
 * Kaikki tyylit on rajattu .ga-wrap / .ga-reviews -luokkien alle, jottei se
 * sekaannu teeman tyyleihin. Taustaväriä EI aseteta -> sivun oma tausta näkyy läpi.
 */

.ga-wrap {
    max-width: 1200px;
    margin: 0 auto;
    background: transparent;
    color: #202124;
}

/* -------- Yläpalkki: keskiarvo + tähdet + määrä / painike -------- */

.ga-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 28px;
}

.ga-summary {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.ga-avg-num {
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    color: #fbfbfb!important;
}

/* Osittain täyttyvä tähtirivi (esim. 4.8 / 5) */
.ga-stars-avg {
    position: relative;
    display: inline-block;
    font-size: 20px;
    line-height: 1;
    white-space: nowrap;
    letter-spacing: 1px;
}

.ga-stars-avg .ga-stars-bg {
    color: #dadce0;
}

.ga-stars-avg .ga-stars-fg {
    color: #d93025;
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
    white-space: nowrap;
}

.ga-count {
    font-size: 14px;
    color: #70757a;
}

/* -------- "Kirjoita arvostelu" -painike -------- */

.ga-write-btn,
.ga-write-btn:link,
.ga-write-btn:visited {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #c0410f;
    color: #fff !important;
    text-decoration: none;
    font-size: 15px;
    font-weight: 400 !important;
    line-height: 1;
    padding: 12px 20px;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
    transition: background-color 0.15s ease, transform 0.05s ease, box-shadow 0.15s ease;
}

.ga-write-btn:hover,
.ga-write-btn:focus,
.ga-write-btn:active {
    background: #a5360b;
    color: #fff !important;
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.22);
}

.ga-write-btn:active {
    transform: translateY(1px);
}

/* Teksti ja ikoni valkoisiksi, vaikka teema yrittäisi ylikirjoittaa */
.ga-write-btn span {
    color: #fff !important;
    font-weight: 400 !important;
}

.ga-write-btn .ga-pencil {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #fff !important;
    fill: #fff !important;
}

.ga-write-btn .ga-pencil path {
    fill: #fff !important;
}

/* -------- Arvostelukortit -------- */

.ga-reviews {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: start;
    background: transparent;
}

@media (max-width: 992px) {
    .ga-reviews { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .ga-reviews { grid-template-columns: 1fr; }
}

.ga-reviews .ga-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    padding: 24px;
    box-sizing: border-box;
    border: 1px solid #ebebeb;
    break-inside: avoid;
}

.ga-reviews .ga-card.ga-hidden {
    display: none;
}

.ga-reviews .ga-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 16px;
}

.ga-reviews .ga-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    margin-right: 16px;
    object-fit: cover;
    background-color: #607d8b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #fff;
    font-weight: bold;
    flex-shrink: 0;
}

.ga-reviews .ga-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 48px;
}

.ga-reviews .ga-name {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 2px;
    line-height: 1.2;
}

.ga-reviews .ga-date {
    font-size: 13px;
    color: #70757a;
}

.ga-reviews .ga-rating {
    margin-bottom: 12px;
    display: flex;
    gap: 2px;
}

.ga-reviews .ga-star {
    color: #d93025;
    font-size: 18px;
    line-height: 1;
}

.ga-reviews .ga-text {
    font-size: 14px;
    line-height: 1.5;
    color: #4d5156;
    margin: 0;
}

.ga-reviews .ga-empty {
    text-align: center;
    padding: 40px;
    font-size: 16px;
    color: #70757a;
    grid-column: 1 / -1;
}

/* -------- "Lataa lisää" -painike -------- */

.ga-loadmore-wrap {
    text-align: center;
    margin-top: 32px;
}

.ga-loadmore {
    display: inline-block;
    background: #fff;
    color: #202124;
    border: 1px solid #dadce0;
    border-radius: 24px;
    padding: 11px 28px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
    transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.ga-loadmore:hover,
.ga-loadmore:focus {
    background: #f8f9fa;
    border-color: #c0c4c9;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
