/* =========================================================
 * Info Bar — frontend stílus
 *  - Alulról felcsúszó sáv (transform-mal animálva)
 *  - Görgetésre jelenik meg (JS adja a .is-visible osztályt)
 *  - X gombbal bezárható
 *  - Responsive (mobilon kompaktabb)
 * ========================================================= */

.info-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9998;
      background: #11b981;
    border-top: 1px solid #ffffff;
    color: #ffffff;
      font-family: "Poppins", Sans-serif;
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.25);
    transform: translateY(100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                opacity   0.35s ease,
                visibility 0s linear 0.45s;
    font-family: inherit;
}

.info-bar[hidden] {
    display: block; /* a JS állítja a láthatóságot, a hidden csak SSR-default */
}

.info-bar.is-visible {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                opacity   0.35s ease,
                visibility 0s linear 0s;
}

.info-bar__inner {
    max-width: 1400px;
    font-family: "Poppins", Sans-serif;
    margin: 0 auto;
    padding: 12px 56px 12px 24px; /* jobbra hely a × gombnak */
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
    position: relative;
}

.info-bar__text {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: 0.2px;
    margin-right: 8px;
    flex: 0 1 auto;
}

.info-bar__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    flex: 1 1 auto;
    justify-content: flex-start;
}

.info-bar__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #ffffff;
    color: #11b981;
    text-decoration: none;
    border-radius: 999px;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.2;
    transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
    white-space: nowrap;
}

.info-bar__btn:hover,
.info-bar__btn:focus-visible {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-1px);
    color: #ffffff;
    text-decoration: none;
    outline: none;
}

.info-bar__icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}

.info-bar__btn-text {
    display: inline-block;
}

.info-bar__close {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
}

.info-bar__close:hover,
.info-bar__close:focus-visible {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-50%) rotate(90deg);
    outline: none;
}

/* --- Responsive ------------------------------------------- */

@media (max-width: 1023px) {
    .info-bar__inner {
        padding: 10px 48px 10px 16px;
        gap: 14px;
    }
    .info-bar__text {
        font-size: 1rem;
        width: 100%;
        margin-right: 0;
    }
    .info-bar__buttons {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .info-bar__inner {
        padding: 28px 12px 12px;  /* felül több hely az X gombnak */
        gap: 10px;
    }
    .info-bar__text {
        font-size: 0.95rem;
        text-align: center;
        width: 100%;
    }
    .info-bar__buttons {
        width: 100%;
        flex-wrap: nowrap;          /* 2 gomb egymás mellett, ne törjön sorba */
        justify-content: center;
        gap: 8px;
    }
     .info-bar__btn {
        flex: 1 1 0;
        min-width: 0;
        justify-content: center;
        padding: 10px 7px;
        font-size: 12px;
    }
    .info-bar__btn-text {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .info-bar__icon {
        width: 18px;
        height: 18px;
        flex-shrink: 0;
    }
    .info-bar__close {
        width: 28px;
        height: 28px;
        top: 6px;                   /* kicsit feljebb, abszolút pozícióban */
        right: 8px;
        transform: none;            /* nincs vertical centering */
        font-size: 20px;
    }
    .info-bar__close:hover,
    .info-bar__close:focus-visible {
        transform: rotate(90deg);   /* center-transform nélkül */
    }
}

/* Preferált csökkentett mozgás (akadálymentesség) */
@media (prefers-reduced-motion: reduce) {
    .info-bar,
    .info-bar.is-visible,
    .info-bar__btn,
    .info-bar__close {
        transition: none !important;
    }
}
