/* Holiday Notice Bar */
.hn-notice-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 999999;
}

#hn-notice-bar {
    position: relative;
    width: 100%;
    padding: 12px 50px 12px 20px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

#hn-notice-bar:hover {
    filter: brightness(1.05);
}

.hn-bar-content {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.hn-marquee {
    display: flex;
    width: 100%;
}

.hn-marquee-content {
    display: flex;
    animation: hn-scroll 30s linear infinite;
    white-space: nowrap;
    flex-shrink: 0;
}

.hn-marquee:hover .hn-marquee-content {
    animation-play-state: paused;
}

.hn-marquee-item {
    padding: 0 50px;
    display: inline-block;
}

@keyframes hn-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* HINT ANIMÁCIE - sú na notice-bar, nie na wrapper */

/* 1. Zobák */
#hn-notice-bar.hn-hint-pointer::after {
    content: "";
    position: absolute;
    bottom: -12px;
    left: 50%;
    width: 28px;
    height: 16px;
    clip-path: polygon(50% 100%, 0 0, 100% 0);
    animation: zobakBounce 1.5s infinite ease-in-out;
    pointer-events: none;
    z-index: 1;
}

@keyframes zobakBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(4px); }
}

/* 2. Šípka */
#hn-notice-bar.hn-hint-arrows::after {
    content: "";
    position: absolute;
    bottom: -20px;
    left: 50%;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 12px solid;
    animation: arrowBounce 1.5s infinite ease-in-out;
    pointer-events: none;
    z-index: 1;
}

@keyframes arrowBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); opacity: 1; }
    50% { transform: translateX(-50%) translateY(5px); opacity: 0.6; }
}

/* 3. Chevron */
#hn-notice-bar.hn-hint-chevron::after {
    content: "";
    position: absolute;
    bottom: -18px;
    left: 50%;
    width: 12px;
    height: 12px;
    border-right: 3px solid;
    border-bottom: 3px solid;
    transform: translateX(-50%) rotate(45deg);
    animation: chevronBounce 1.5s infinite ease-in-out;
    pointer-events: none;
    z-index: 1;
}

@keyframes chevronBounce {
    0%, 100% { transform: translateX(-50%) rotate(45deg) translateY(0); opacity: 1; }
    50% { transform: translateX(-50%) rotate(45deg) translateY(4px); opacity: 0.5; }
}

/* 4. Pulzujúci kruh */
#hn-notice-bar.hn-hint-pulse_circle::after {
    content: "";
    position: absolute;
    bottom: -20px;
    left: 50%;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    transform: translateX(-50%);
    pointer-events: none;
    z-index: 1;
}

#hn-notice-bar.hn-hint-pulse_circle::before {
    content: "";
    position: absolute;
    bottom: -20px;
    left: 50%;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid;
    transform: translateX(-50%);
    animation: pulseRing 1.8s infinite ease-out;
    pointer-events: none;
    z-index: 1;
}

@keyframes pulseRing {
    0% { transform: translateX(-50%) scale(1); opacity: 0.8; }
    100% { transform: translateX(-50%) scale(2.5); opacity: 0; }
}

/* 5. Dvojitá šípka */
#hn-notice-bar.hn-hint-double_arrow::before,
#hn-notice-bar.hn-hint-double_arrow::after {
    content: "";
    position: absolute;
    left: 50%;
    width: 10px;
    height: 10px;
    border-right: 2px solid;
    border-bottom: 2px solid;
    pointer-events: none;
    z-index: 1;
}

#hn-notice-bar.hn-hint-double_arrow::before {
    bottom: -16px;
    transform: translateX(-50%) rotate(45deg);
    animation: doubleArrow1 1.6s infinite ease-in-out;
}

#hn-notice-bar.hn-hint-double_arrow::after {
    bottom: -22px;
    transform: translateX(-50%) rotate(45deg);
    animation: doubleArrow2 1.6s infinite ease-in-out;
}

@keyframes doubleArrow1 {
    0%, 100% { opacity: 0; transform: translateX(-50%) rotate(45deg) translateY(-3px); }
    50% { opacity: 1; transform: translateX(-50%) rotate(45deg) translateY(0); }
}

@keyframes doubleArrow2 {
    0% { opacity: 0; transform: translateX(-50%) rotate(45deg) translateY(-3px); }
    50% { opacity: 1; transform: translateX(-50%) rotate(45deg) translateY(0); }
    100% { opacity: 0; transform: translateX(-50%) rotate(45deg) translateY(3px); }
}

/* Tlačidlo - je súčasť wrapper, nie bar */
.hn-button {
    display: block;
    margin: 0 auto;
    padding: 10px 28px;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    position: relative;
    width: fit-content;
    margin-top: 12px;
}

.hn-button:hover {
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

/* Wrapper má padding iba keď je tlačidlo */
.hn-notice-wrapper.hn-has-button {
    padding-bottom: 8px;
}

/* Close button */
#hn-close-bar {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: inherit;
    font-size: 28px;
    cursor: pointer;
    padding: 5px 10px;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.3s, transform 0.2s;
    z-index: 10;
}

#hn-close-bar:hover {
    opacity: 1;
    transform: translateY(-50%) rotate(90deg);
}

body.hn-bar-closed .hn-notice-wrapper {
    display: none;
}

body.hn-bar-closed .hn-notice-wrapper {
    display: none;
}

body.hn-bar-closed .site-header,
body.hn-bar-closed header.site-header,
body.hn-bar-closed .header,
body.hn-bar-closed #masthead {
    margin-top: 0 !important;
}

/* Popup */
#hn-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999999;
    justify-content: center;
    align-items: center;
}

#hn-popup-overlay.active {
    display: flex;
}

#hn-popup {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

#hn-popup h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
}

.hn-popup-content {
    line-height: 1.6;
    color: #666;
}

.hn-popup-content ul {
    padding-left: 20px;
}

.hn-popup-content li {
    margin-bottom: 8px;
}

#hn-close-popup {
    position: absolute;
    right: 15px;
    top: 15px;
    background: transparent;
    border: none;
    font-size: 30px;
    cursor: pointer;
    color: #999;
    padding: 5px 10px;
    line-height: 1;
    transition: color 0.3s, transform 0.2s;
}

#hn-close-popup:hover {
    color: #333;
    transform: rotate(90deg);
}

@media (max-width: 768px) {
    #hn-notice-bar {
        font-size: 14px;
        padding: 10px 40px 10px 15px;
    }
    
    .hn-marquee-item {
        padding: 0 30px;
    }
    
    .hn-button {
        padding: 8px 20px;
        margin-top: 10px;
    }
    
    .hn-notice-wrapper.hn-has-button {
        padding-bottom: 6px;
    }
    
    #hn-notice-bar.hn-hint-pointer::after,
    #hn-notice-bar.hn-hint-arrows::after,
    #hn-notice-bar.hn-hint-chevron::after,
    #hn-notice-bar.hn-hint-pulse_circle::after,
    #hn-notice-bar.hn-hint-pulse_circle::before,
    #hn-notice-bar.hn-hint-double_arrow::after,
    #hn-notice-bar.hn-hint-double_arrow::before {
        display: none;
    }
    
    #hn-popup {
        padding: 30px 20px;
    }
}