/* =============================================
   Hnojik Google Reviews — Top Bar Banner
   ============================================= */

.hgr-toast-wrapper {
    position: fixed;
    z-index: 9998;
    pointer-events: none;
    top: 0;
    left: 0;
    right: 0;
}

/* Toast banner — dva kompaktní řádky nahoře */
.hgr-toast {
    width: 100%;
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 6px 12px;
    pointer-events: auto;
    cursor: default;
    position: relative;

    display: flex;
    flex-direction: column;
    gap: 2px;

    /* Animace — slide z vrchu */
    transform: translateY(-100%);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.hgr-toast--visible {
    transform: translateY(0);
    opacity: 1;
}

.hgr-toast--closing {
    transform: translateY(-100%);
    opacity: 0;
}

/* Google logo — na začátku */
.hgr-toast__google {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Header — řádek: logo + avatar + jméno + hvězdy + datum ... close */
.hgr-toast__header {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

/* Avatar obrázek */
.hgr-toast__avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

/* Avatar fallback — iniciála */
.hgr-toast__avatar-initial {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #4285F4;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 12px;
    flex-shrink: 0;
    line-height: 1;
}

/* Meta info (jméno + hvězdy) */
.hgr-toast__meta {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.hgr-toast__name {
    font-weight: 600;
    font-size: 14px;
    color: #1a1a1a;
    line-height: 1;
    white-space: nowrap;
}

/* Hvězdy — inline */
.hgr-toast__stars {
    display: flex;
    gap: 0;
}

.hgr-toast__star {
    font-size: 13px;
    line-height: 1;
}

.hgr-toast__star--filled {
    color: #FBBC04;
}

.hgr-toast__star--empty {
    color: #dadce0;
}

/* Text recenze — přes celou šířku, max 2 řádky */
.hgr-toast__text {
    font-size: 14px;
    line-height: 1.35;
    color: #555;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    width: 100%;
}

/* "Celá recenze" odkaz */
.hgr-toast__expand {
    color: #4285F4;
    cursor: pointer;
    font-size: 12px;
    border: none;
    background: none;
    padding: 0;
    text-decoration: underline;
    white-space: nowrap;
    flex-shrink: 0;
}

.hgr-toast__expand:hover {
    color: #1a73e8;
}

/* Datum — nenápadné, v hlavičce */
.hgr-toast__date {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
}

/* Close tlačítko — nenápadné šedé × */
.hgr-toast__close {
    width: 16px;
    height: 16px;
    border: none;
    background: transparent;
    color: #ccc;
    font-size: 14px;
    line-height: 16px;
    text-align: center;
    cursor: pointer;
    border-radius: 50%;
    padding: 0;
    flex-shrink: 0;
    margin-left: auto;
    transition: color 0.2s;
    pointer-events: auto;
    opacity: 0.6;
}

.hgr-toast__close:hover {
    color: #999;
    opacity: 1;
}

/* =============================================
   Mobile — kompaktnější
   ============================================= */
@media (max-width: 600px) {
    .hgr-toast {
        padding: 5px 8px;
        gap: 2px;
    }

    .hgr-toast__header {
        gap: 4px;
    }

    .hgr-toast__name {
        font-size: 11px;
    }

    .hgr-toast__avatar,
    .hgr-toast__avatar-initial {
        width: 18px;
        height: 18px;
        font-size: 9px;
    }

    .hgr-toast__google {
        width: 14px;
        height: 14px;
    }

    .hgr-toast__star {
        font-size: 10px;
    }

    .hgr-toast__date {
        font-size: 10px;
    }

    .hgr-toast__text {
        font-size: 12px;
    }

    .hgr-toast__close {
        width: 16px;
        height: 16px;
        font-size: 13px;
        line-height: 16px;
    }
}

/* =============================================
   Footer card varianta — vlevo dole nad patičkou
   ============================================= */

.hgr-toast-wrapper--footer {
    position: fixed;
    top: auto;
    bottom: 70px; /* nad Elementor patičkou */
    left: 12px;
    right: auto;
    z-index: 9998;
    pointer-events: none;
    width: 340px;
    max-width: calc(100vw - 24px);
}

.hgr-toast--footer {
    width: 100%;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    border: 1px solid #e8e8e8;
    padding: 12px 14px;
    pointer-events: auto;
    cursor: default;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;

    /* Animace — slide z dola */
    transform: translateY(30px);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.hgr-toast--footer.hgr-toast--visible {
    transform: translateY(0);
    opacity: 1;
}

.hgr-toast--footer.hgr-toast--closing {
    transform: translateY(30px);
    opacity: 0;
}

.hgr-toast--footer .hgr-toast__footer-top {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hgr-toast--footer .hgr-toast__meta {
    flex: 1;
    min-width: 0;
}

.hgr-toast--footer .hgr-toast__name {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hgr-toast--footer .hgr-toast__stars {
    display: flex;
    align-items: center;
    gap: 0;
}

.hgr-toast--footer .hgr-toast__text {
    font-size: 13px;
    line-height: 1.4;
    color: #555;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: normal;
}

.hgr-toast--footer .hgr-toast__close {
    position: static;
    flex-shrink: 0;
    margin-left: auto;
}

@media (max-width: 600px) {
    .hgr-toast-wrapper--footer {
        bottom: 80px;
        left: 8px;
        width: 280px;
    }

    .hgr-toast--footer {
        padding: 10px 12px;
    }

    .hgr-toast--footer .hgr-toast__text {
        font-size: 12px;
        -webkit-line-clamp: 2;
    }
}

/* =============================================
   Reduced motion
   ============================================= */
@media (prefers-reduced-motion: reduce) {
    .hgr-toast {
        transition: none;
    }
}
