#cookie-popup {
    position: fixed;
    bottom: 0;
    width: 100%;
    max-width: 100%;
    min-width: 100%;
    background-color: white;
    box-shadow: 0px -2px 10px rgba(0, 0, 0, 0.2);
    padding: 20px;
    display: none;
    z-index: 1000;
    box-sizing: border-box;
    height: auto;
    min-height: 250px;
    transition: 0.3s ease;
}

#cookie-popup .cookie-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.cookie-left,
.cookie-center,
.cookie-right {
    display: flex;
    align-items: center;
}

/* LEFT SIDE */
.cookie-left {
    flex: 1;
    justify-content: center;
}

.cookie-logo {
    max-width: 175px !important;
    height: auto;
}

/* CENTER */
.cookie-center {
    flex: 2;
    text-align: left;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
}

.cookie-center p {
    color: #333;
}

.site-uses-cookie {
    font-weight: bold;
    font-size: 17px;
    margin-bottom: 10px;
}

.cookie-use-info {
    margin: 0;
    text-align: justify;
}

/* Footer popup details button */
.footer-details-btn {
    background-color: transparent !important;
    border: none;
    cursor: pointer;
    margin-top: 20px;
    padding: 0 !important;
    text-align: left;
    font-weight: bold;
    transition: 0.3s ease;
    display: block;
}

.footer-details-btn:hover {
    background-color: transparent !important;
}

/* Floating popup details button */
.floating-details-btn {
    display: none;
}

/* RIGHT SIDE */
.cookie-right {
    flex: 1;
    justify-content: center;
    flex-direction: column;
}

.cookie-btn {
    background-color: #0073e6;
    border: none;
    padding: 20px 20px;
    font-size: 17px;
    cursor: pointer;
    border-radius: 2px;
    transition: background-color 0.3s ease;
    width: 240px;
    font-weight: bold;
}

.cookie-btn.reject-btn {
    margin-top: 10px;
    background-color: white;
    color: #333;
    border: 1px solid #0073e6;
}

@media (max-width: 1024px) {
    #cookie-popup .cookie-content {
        flex-direction: column;
        text-align: center;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-left,
    #cookie-popup:not(.cookie-popup-floating) .cookie-center,
    #cookie-popup:not(.cookie-popup-floating) .cookie-right {
        width: 100%;
        justify-content: flex-start;
        margin-top: 10px;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-btn {
        margin-top: 10px;
        width: 100%;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-center {
        max-height: 30vh;
        overflow-y: scroll;
        padding-right: 10px;
        scroll-behavior: smooth;
        position: relative;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-center::-webkit-scrollbar {
        width: 0;
        height: 0;
        display: none;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-center {
        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    #cookie-popup:not(.cookie-popup-floating) .cookie-logo {
        max-width: 100px !important;
    }
}

/* Részletek Popup alap stílusok */
.cookie-details-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 20px rgba(0, 0, 0, 0.2);
    width: 1000px;
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease;
    z-index: 1001;
    height: 800px;
}

.cookie-details-popup.active {
    display: block;
    opacity: 1;
}

.cookie-category-container {
    max-height: 530px;
    overflow-y: auto;
    margin-top: 10px;
    margin-bottom: 10px;
    padding-right: 10px;
    position: relative;
}

/* Accordion stílusok */
.cookie-accordion {
    background-color: #f1f1f1;
    color: #333;
    cursor: pointer;
    padding: 15px;
    width: 100%;
    text-align: left;
    font-size: 17px;
    font-weight: bold;
    border: none;
    outline: none;
    transition: background-color 0.2s ease;
    margin-bottom: 5px;
    border-radius: 2px;
    position: relative;
}

.cookie-accordion::after {
    content: '';
    position: absolute;
    right: 20px;
    top: 50%;
    width: 24px;
    height: 24px;
    background-image: url('data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22 fill=%22none%22 stroke=%22currentColor%22 stroke-width=%222%22 stroke-linecap=%22round%22 stroke-linejoin=%22round%22 class=%22feather feather-chevron-down%22%3E%3Cpolyline points=%226 9 12 15 18 9%22/%3E%3C/svg%3E');
    background-size: contain;
    background-repeat: no-repeat;
    transform: translateY(-50%);
    transition: transform 0.3s ease;
}

.cookie-accordion.active::after {
    transform: translateY(-50%) rotate(180deg);
}

.cookie-accordion.active {
    color: white;
}

/* Panel stílusok */
.cookie-panel {
    padding: 10px 18px;
    overflow: hidden;
    background-color: white;
    transition: max-height 0.3s ease-in-out, padding 0.3s ease-in-out;
    margin-top: 10px;
    margin-bottom: 10px;
}

.cookie-panel p {
    margin: 10px 0;
    color: #333;
    display: block;
    visibility: visible;
}

.cookie-panel.open {
    max-height: 200px;
    padding: 10px 18px;
}

.cookie-panel .cookie-list {
    display: none;
}

.cookie-panel.open .cookie-list {
    display: block;
}

.cookie-logo-details {
    max-width: 130px !important;
    height: auto;
}

/* Alsó gombok
   .details-popup-footer → .cookie-details-popup-footer */
.cookie-details-popup-footer {
    display: flex;
    justify-content: space-between;
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    width: calc(100% - 40px);
}

.cookie-details-popup-footer .cookie-btn {
    width: 48%;
    margin-top: 0;
}

@media (max-width: 1024px) {
    .cookie-details-popup {
        width: 90%;
        padding: 15px;
        max-height: 85vh;
    }

    .cookie-accordion {
        font-size: 16px;
    }

    /* .details-popup-footer → .cookie-details-popup-footer */
    .cookie-details-popup-footer {
        flex-direction: column;
        align-items: center;
    }

    .cookie-details-popup-footer .cookie-btn {
        width: 100%;
    }

    .cookie-details-popup-footer .cookie-btn:last-child {
        margin-bottom: 0;
        margin-top: 5px;
    }

    .cookie-category-container {
        max-height: 45vh;
    }

    .cookie-logo-details {
        max-width: 100px !important;
    }

    .cookie-category-container {
        margin-top: 0;
        margin-bottom: 0;
    }
}

@media (max-height: 880px) {
    .cookie-details-popup {
        height: 90% !important;
        max-height: 90% !important;
    }

    .cookie-category-container {
        max-height: 450px;
    }
}

@media (max-height: 790px) {
    .cookie-category-container {
        max-height: 400px;
    }
}

.cookie-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.cookie-description {
    flex: 1;
    margin-right: 20px;
}

/* Switch stílusok */
.cookie-switch {
    position: relative;
    display: inline-block;
    width: 43px;
    height: 24px;
    margin-left: 5px;
}

.cookie-switch input[type="checkbox"] {
    opacity: 0;
    width: 0;
    height: 0;
}

/* Slider stílusok */
.cookie-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 20px;
}

.cookie-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

/* Kapcsoló állapotok */
input[type="checkbox"]:checked + .cookie-slider:before {
    transform: translateX(18px);
}

input[type="checkbox"]:disabled + .cookie-slider {
    background-color: #aaa;
    cursor: not-allowed;
}

input[type="checkbox"]:disabled + .cookie-slider:before {
    background-color: #ddd;
}

/* BOTTOM LEFT SETTING ICON */
#cookie-settings-icon {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #ffffff;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.35);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    overflow: hidden;
    padding: 0;
    transition: 0.3s all ease;
}

#cookie-settings-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#cookie-settings-icon:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.7);
}

.close-details-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: transparent !important;
    border: none;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    color: #333 !important;
}

.close-details-btn:hover {
    color: #000;
    background-color: none !important;
}

.close-details-btn:active {
	background-color: transparent !important;
}

/* Floating Cookie Popup Styles */
#cookie-popup.cookie-popup-floating {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    bottom: auto;
    width: 600px;
    max-width: 90vw;
    min-width: auto;
    min-height: 400px;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0px 4px 20px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease;
    z-index: 1001;
}

#cookie-popup.cookie-popup-floating.active {
    opacity: 1;
}

#cookie-popup.cookie-popup-floating .cookie-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    height: 100%;
}

#cookie-popup.cookie-popup-floating .cookie-left {
    flex: none;
    margin-bottom: 30px;
}

#cookie-popup.cookie-popup-floating .cookie-logo {
    max-width: 130px !important;
}

#cookie-popup.cookie-popup-floating .cookie-center {
    flex: 1;
    text-align: center;
    margin-bottom: 35px;
}

#cookie-popup.cookie-popup-floating .site-uses-cookie {
    font-size: 22px;
    margin-bottom: 20px;
}

#cookie-popup.cookie-popup-floating .cookie-use-info {
    text-align: justify;
    line-height: 1.6;
    font-size: 15px;
}

#cookie-popup.cookie-popup-floating .cookie-right {
    flex: none;
    width: 100%;
    flex-direction: column;
    gap: 15px;
}

/* Hide footer details button in floating popup, show floating details button */
#cookie-popup.cookie-popup-floating .footer-details-btn {
    display: none;
}

#cookie-popup.cookie-popup-floating .floating-details-btn {
    display: block;
    width: 100%;
    margin: 0;
    padding: 20px 20px;
    font-size: 17px;
}

#cookie-popup.cookie-popup-floating .cookie-btn {
    width: 100%;
    margin: 0;
    padding: 20px 20px;
    font-size: 17px;
}


@media (max-width: 1024px) {
    #cookie-popup.cookie-popup-floating {
        width: 90%;
        padding: 30px;
        min-height: 350px;
    }

    #cookie-popup.cookie-popup-floating .site-uses-cookie {
        font-size: 20px;
    }

    #cookie-popup.cookie-popup-floating .cookie-use-info {
        font-size: 14px;
    }

    #cookie-popup.cookie-popup-floating .cookie-logo {
        max-width: 100px !important;
    }
}

@media (max-width: 768px) {
    /* The floating card of the plugin this replaces, unchanged on every site that
       runs it: 95vw wide with 25px padding. The height cap only shows on phones too
       short for the extra "necessary only" row, where the card scrolls instead of
       running off the screen. */
    #cookie-popup.cookie-popup-floating {
        width: 95vw;
        padding: 25px;
        min-height: 300px;
        max-height: 90vh;
        max-height: 90dvh;
        overflow-y: auto;
    }

    #cookie-popup.cookie-popup-floating .site-uses-cookie {
        font-size: 18px;
    }

    #cookie-popup.cookie-popup-floating .cookie-use-info {
        font-size: 13px;
        text-align: left;
    }

    #cookie-popup.cookie-popup-floating .cookie-logo {
        max-width: 80px !important;
        margin-bottom: 20px;
    }

    #cookie-popup.cookie-popup-floating .cookie-btn {
        padding: 15px 20px;
        font-size: 16px;
    }
}
/* --- bpcookie additions --- */
#cookie-popup[hidden],
#cookie-settings-icon[hidden] {
    display: none;
}

#cookie-popup .cookie-policy-link {
    text-decoration: underline;
    color: inherit;
    margin-left: 4px;
}

#cookie-details-popup .cookie-count {
    font-weight: normal;
    opacity: 0.8;
}
