/**
 * DirectPrint for PrestaShop
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to a commercial license.
 * A copy of that license is shipped with this module, in docs/LICENSE.md.
 * If you did not receive it, please write to contact@pixelorigin.com.
 *
 * @author    Pixelorigin <contact@pixelorigin.com>
 * @copyright Since 2025 Pixelorigin
 * @license   Commercial license, see docs/LICENSE.md
 */

/* Shop closed: banner pinned at the top of every page. */
.directprint-closed-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    margin: 0;
    border-radius: 0;
    padding: 12px 20px;
    text-align: center;
    font-size: 15px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* The banner is fixed, so it is followed by a spacer that pushes the page content down. */
.directprint-closed-banner-spacer {
    height: 56px;
}

/* Notice shown bottom right when the customer tries to order while the shop is closed.
   It appears, stays a few seconds, then fades away on its own. */
.directprint-popup {
    position: fixed;
    bottom: 20px;
    right: 20px;
    min-width: 250px;
    max-width: 340px;
    margin: 0;
    z-index: 100000;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .25s ease-out, transform .25s ease-out;
}

.directprint-popup--shown {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 767px) {
    .directprint-popup {
        bottom: 10px;
        right: 10px;
        left: 10px;
        min-width: 0;
        max-width: none;
    }
}

/* The banner blinks a few times to draw the eye, then settles down. */
@keyframes directprint-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: .25; }
}

.directprint-closed-banner--blink {
    animation: directprint-blink .45s ease-in-out 3;
}

/* Nothing moves for a visitor who asked for reduced motion. */
@media (prefers-reduced-motion: reduce) {
    .directprint-popup {
        transition: none;
    }

    .directprint-closed-banner--blink {
        animation: none;
    }
}
