/* ==========================================================================
   Homepage hero: "BE PREPARED" Black Friday campaign
   Used by resources/views/partials/homepage/hero-next.blade.php
   Layout follows the campaign poster:
   - Top band: teal background with kraft tape strips, big yellow title,
     and a short Black Friday message.
   - Bottom band: yellow background, three numbered product cards (01-03),
     a purple "packaging solutions" title and an arrow link.
   All classes start with "bf-" so they never clash with the rest of the page.
   ========================================================================== */

.bf-hero {
    /* Campaign colours, taken from the poster */
    --bf-teal: #5fbdb6;
    --bf-teal-dark: #3f9c95;
    --bf-yellow: #f6bc16;
    --bf-purple: #4a2c8c;
    --bf-kraft: #c99d66;
    --bf-ink: #2b2140;

    /* Fonts: both support Greek. Loaded in the hero partial. */
    --bf-display: 'Commissioner', 'Manrope', sans-serif;
    --bf-mono: 'Fira Code', ui-monospace, monospace;

    position: relative;
    overflow: hidden;
}

/* --------------------------------------------------------------------------
   Top band
   To use a real campaign photo instead of the CSS tape strips:
   add style="background-image:url('/path/photo.jpg')" on .bf-top
   and remove the .bf-tape elements from the partial.
   -------------------------------------------------------------------------- */
.bf-top {
    position: relative;
    background-color: var(--bf-teal);
    background-size: cover;
    background-position: center;
    padding: 90px 20px 80px;
    text-align: center;
    isolation: isolate;
    /* Keep the rotated tape strips inside the teal band */
    overflow: hidden;
}

/* Soft dark corners, so the yellow title always reads well */
.bf-top::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background: radial-gradient(ellipse at center, transparent 40%, rgba(20, 60, 58, 0.25) 100%);
}

/* Kraft tape strips with the brand printed on them */
.bf-tape {
    position: absolute;
    z-index: -2;
    left: -20%;
    width: 140%;
    height: 96px;
    display: flex;
    align-items: center;
    overflow: hidden;
    white-space: nowrap;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), transparent 30%, transparent 70%, rgba(0, 0, 0, 0.12)),
        var(--bf-kraft);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
    font-family: var(--bf-display);
    font-weight: 800;
    font-size: 2.6rem;
    letter-spacing: 0.04em;
    color: rgba(150, 110, 200, 0.55);
    animation: bfTapeIn 1s cubic-bezier(.2, .8, .2, 1) both;
}

.bf-tape--one {
    top: 18%;
    transform: rotate(-16deg);
}

.bf-tape--two {
    bottom: 4%;
    transform: rotate(-16deg);
    animation-delay: 0.15s;
}

@keyframes bfTapeIn {
    from { opacity: 0; translate: -8% 0; }
    to { opacity: 1; translate: 0 0; }
}

.bf-title {
    font-family: var(--bf-display);
    font-weight: 900;
    font-size: clamp(3.2rem, 9vw, 7.5rem);
    line-height: 0.92;
    letter-spacing: -0.01em;
    color: var(--bf-yellow);
    text-transform: uppercase;
    text-shadow: 0 6px 0 rgba(0, 0, 0, 0.12);
    /* Narrow width so "BE PREPARED" breaks onto two lines */
    max-width: 9ch;
    margin: 0 auto 28px;
}

.bf-message {
    display: inline-block;
    max-width: 560px;
    margin: 0;
    padding: 14px 20px;
    border-radius: 6px;
    background: rgba(63, 156, 149, 0.88);
    font-family: var(--bf-mono);
    font-size: 1rem;
    line-height: 1.6;
    color: #fff;
}

.bf-message strong {
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   Bottom band
   -------------------------------------------------------------------------- */
.bf-bottom {
    background: var(--bf-yellow);
    padding: 70px 20px 60px;
}

.bf-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    max-width: 980px;
    margin: 0 auto;
}

.bf-card {
    position: relative;
    display: block;
    padding-top: 34px; /* room for the big number above the card */
    text-decoration: none;
}

/* Big outlined number, sitting on the top-right corner like the poster */
.bf-card__number {
    position: absolute;
    top: 0;
    right: -6px;
    z-index: 2;
    font-family: var(--bf-display);
    font-weight: 900;
    font-size: 4.2rem;
    line-height: 1;
    color: var(--bf-yellow);
    -webkit-text-stroke: 3px var(--bf-purple);
    paint-order: stroke fill;
    transition: transform 0.3s ease;
}

.bf-card__image {
    position: relative;
    aspect-ratio: 4 / 5;
    background: #fff;
    overflow: hidden;
    box-shadow: 0 14px 30px rgba(74, 44, 140, 0.18);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.bf-card__image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 8%;
    transition: transform 0.5s ease;
}

/* Product name slides up on hover, so the card stays clean like the poster */
.bf-card__label {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 10px 14px;
    background: var(--bf-purple);
    color: #fff;
    font-family: var(--bf-mono);
    font-size: 0.8rem;
    line-height: 1.4;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.bf-card:hover .bf-card__image,
.bf-card:focus-visible .bf-card__image {
    transform: translateY(-6px) rotate(-1deg);
    box-shadow: 0 22px 40px rgba(74, 44, 140, 0.28);
}

.bf-card:hover .bf-card__image img {
    transform: scale(1.05);
}

.bf-card:hover .bf-card__label,
.bf-card:focus-visible .bf-card__label {
    transform: translateY(0);
}

.bf-card:hover .bf-card__number {
    transform: translateY(-6px) rotate(4deg);
}

.bf-solutions {
    max-width: 980px;
    margin: 50px auto 0;
    text-align: center;
}

.bf-solutions__title {
    font-family: var(--bf-display);
    font-weight: 900;
    font-size: clamp(2rem, 5vw, 3.6rem);
    line-height: 1;
    color: var(--bf-purple);
    text-transform: uppercase;
    margin: 0 0 16px;
}

.bf-solutions__text {
    font-family: var(--bf-mono);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--bf-ink);
    margin: 0 auto;
    max-width: 520px;
}

.bf-solutions__text strong {
    font-weight: 600;
}

/* Arrow link, bottom right like "-> packitup.gr" on the poster */
.bf-link {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
    max-width: 980px;
    margin: 36px auto 0;
    font-family: var(--bf-mono);
    font-size: 1.1rem;
    color: var(--bf-purple);
    text-decoration: none;
}

.bf-link__arrow {
    position: relative;
    width: 120px;
    height: 2px;
    background: #3f6fb5;
    transition: width 0.3s ease;
}

.bf-link__arrow::after {
    content: '';
    position: absolute;
    right: -1px;
    top: -5px;
    border: 6px solid transparent;
    border-left: 9px solid #3f6fb5;
    border-right: 0;
}

.bf-link:hover {
    color: var(--bf-purple);
}

.bf-link:hover .bf-link__arrow {
    width: 160px;
}

/* --------------------------------------------------------------------------
   Load animation: content fades up one piece after the other
   -------------------------------------------------------------------------- */
.bf-reveal {
    animation: bfReveal 0.7s cubic-bezier(.2, .8, .2, 1) both;
}

.bf-reveal--1 { animation-delay: 0.1s; }
.bf-reveal--2 { animation-delay: 0.25s; }
.bf-reveal--3 { animation-delay: 0.4s; }
.bf-reveal--4 { animation-delay: 0.55s; }
.bf-reveal--5 { animation-delay: 0.7s; }

@keyframes bfReveal {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

/* People who prefer less motion get a static hero */
@media (prefers-reduced-motion: reduce) {
    .bf-hero *,
    .bf-hero *::before,
    .bf-hero *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* --------------------------------------------------------------------------
   Mobile
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
    .bf-top {
        padding: 60px 16px 56px;
    }

    .bf-tape {
        height: 64px;
        font-size: 1.7rem;
    }

    .bf-message,
    .bf-solutions__text {
        font-size: 0.88rem;
    }

    .bf-bottom {
        padding: 44px 16px 40px;
    }

    /* Cards scroll sideways, so all three stay big enough to see */
    .bf-cards {
        grid-template-columns: repeat(3, 72%);
        gap: 18px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: 8px;
    }

    .bf-card {
        scroll-snap-align: center;
    }

    .bf-card__number {
        font-size: 3.2rem;
        right: 0;
    }

    /* No hover on touch screens, so always show the product name */
    .bf-card__label {
        transform: none;
    }

    .bf-link {
        justify-content: center;
        font-size: 1rem;
    }

    .bf-link__arrow {
        width: 70px;
    }
}
