/* ═══════════════════════════════════════════════════════════════
   BLACK FRIDAY 2026 — TOP OVERLAY BANNER
   Fixed over the page, never part of the document flow. Visible by
   default; hidden only when <html class="bf-hidden"> is set (expired
   or dismissed) or after the close animation.
   ═══════════════════════════════════════════════════════════════ */

:root {
    --bf-blue: #3b82f6;
    --bf-indigo: #6366f1;
    --bf-violet: #8b5cf6;
    --bf-purple: #a855f7;
    --bf-fuchsia: #d946ef;
    --bf-pink: #ec4899;
    --bf-lavender: #c4b5fd;
    --bf-text: #f7f5ff;
    --bf-muted: #a9a4c6;
    --bf-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --bf-gradient: linear-gradient(100deg, #3b82f6 0%, #8b5cf6 38%, #c026d3 66%, #ec4899 100%);
}

/* ── Banner shell ────────────────────────────────────────────── */
.bf-overlay {
    display: block;
    position: absolute;
    top: var(--bf-top, 70px);
    left: 0;
    right: 0;
    z-index: 900;
    width: 100%;
    overflow: hidden;
    border: 0;
    border-bottom: 1px solid rgba(196, 181, 253, 0.18);
    border-radius: 0;
    color: var(--bf-text);
    background:
        radial-gradient(circle at 8% 30%, rgba(255, 255, 255, 0.6) 0 1.2px, transparent 1.6px),
        radial-gradient(circle at 17% 78%, rgba(196, 181, 253, 0.5) 0 1px, transparent 1.4px),
        radial-gradient(circle at 27% 17%, rgba(255, 255, 255, 0.38) 0 1px, transparent 1.4px),
        radial-gradient(circle at 72% 76%, rgba(244, 114, 182, 0.5) 0 1px, transparent 1.4px),
        radial-gradient(circle at 83% 24%, rgba(255, 255, 255, 0.45) 0 1px, transparent 1.4px),
        radial-gradient(circle at 93% 60%, rgba(147, 197, 253, 0.4) 0 1px, transparent 1.4px),
        radial-gradient(60% 130% at 10% 50%, rgba(59, 130, 246, 0.2), transparent 65%),
        radial-gradient(55% 130% at 90% 50%, rgba(236, 72, 153, 0.16), transparent 65%),
        linear-gradient(180deg, #0a0c22 0%, #060714 100%);
    box-shadow:
        0 26px 70px rgba(8, 6, 30, 0.55),
        0 0 50px rgba(139, 92, 246, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    isolation: isolate;
    animation: bf-in 0.4s var(--bf-ease) both;
}

html.bf-hidden .bf-overlay {
    display: none;
}

/* Reserve room below the header/banner so the hero headline stays visible */
html:not(.bf-hidden) .hero {
    padding-top: calc(10rem + var(--bf-space, 190px));
}

@media (max-width: 768px) {
    html:not(.bf-hidden) .hero {
        padding-top: calc(8rem + var(--bf-space, 190px));
    }
}

/* Thin neon edge along the bottom of the banner */
.bf-overlay::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    pointer-events: none;
    background: linear-gradient(90deg, transparent, #3b82f6, #a855f7, #ec4899, transparent);
    opacity: 0.8;
}

/* Soft aurora behind the content */
.bf-overlay::before {
    content: "";
    position: absolute;
    inset: -25%;
    z-index: -2;
    pointer-events: none;
    background:
        radial-gradient(circle at 18% 50%, rgba(59, 130, 246, 0.24), transparent 42%),
        radial-gradient(circle at 82% 50%, rgba(236, 72, 153, 0.2), transparent 42%),
        radial-gradient(circle at 50% 50%, rgba(139, 92, 246, 0.16), transparent 52%);
    filter: blur(22px);
}

@keyframes bf-in {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.bf-overlay.bf-closing {
    animation: none;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.24s ease, transform 0.24s ease;
}

/* ── Layout ──────────────────────────────────────────────────── */
.bf-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(290px, 340px) auto minmax(200px, 240px);
    align-items: center;
    justify-content: center;
    gap: 1.2rem 1.5rem;
    max-width: 1240px;
    margin: 0 auto;
    padding: 1.1rem 2rem;
}

/* ── Lead: BLACK FRIDAY / 50% RABATT ─────────────────────────── */
.bf-lead {
    position: relative;
    z-index: 0;
    text-align: center;
}

.bf-lead .bf-ring {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: -1;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: conic-gradient(
        from 205deg,
        #3b82f6 0%,
        #6366f1 16%,
        #a855f7 38%,
        #d946ef 62%,
        #ec4899 84%,
        #3b82f6 100%
    );
    -webkit-mask-image: radial-gradient(farthest-side, transparent calc(100% - 2.5px), #000 calc(100% - 1.2px));
    mask-image: radial-gradient(farthest-side, transparent calc(100% - 2.5px), #000 calc(100% - 1.2px));
    filter:
        drop-shadow(0 0 10px rgba(168, 85, 247, 0.75))
        drop-shadow(0 0 28px rgba(236, 72, 153, 0.35));
    pointer-events: none;
}

.bf-kicker {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 0.9;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #fff;
}

.bf-kicker span:last-child {
    color: var(--bf-lavender);
    text-shadow: 0 0 22px rgba(196, 181, 253, 0.4);
}

.bf-headline {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.55rem;
    margin: 0.12rem 0 0.18rem;
}

.bf-percent {
    font-size: clamp(2.9rem, 4.5vw, 3.8rem);
    font-weight: 700;
    line-height: 0.86;
    letter-spacing: -0.055em;
    color: #fff;
    text-shadow: 0 0 40px rgba(196, 181, 253, 0.3);
}

.bf-rabatt {
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #fff;
}

.bf-sub {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.35;
    color: #e6e1ff;
}

/* ── Action: discount code ───────────────────────────────────── */
.bf-action {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}

.bf-code {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 300px;
    max-width: 100%;
    margin: 0;
    padding: 0.55rem 2.6rem;
    border: none;
    border-radius: 999px;
    background: var(--bf-gradient);
    color: #120a2a;
    text-align: center;
    cursor: pointer;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.35),
        0 12px 32px rgba(168, 85, 247, 0.35),
        0 0 0 1px rgba(255, 255, 255, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.bf-code:hover {
    transform: translateY(-2px);
    filter: brightness(1.05);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        0 16px 40px rgba(168, 85, 247, 0.45),
        0 0 0 1px rgba(255, 255, 255, 0.12);
}

.bf-code:active {
    transform: translateY(0) scale(0.99);
}

.bf-code-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.05;
}

.bf-code-label {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: rgba(18, 10, 42, 0.65);
}

.bf-code-value {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
    font-size: 1.12rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #10081f;
}

.bf-code svg {
    position: absolute;
    right: 0.95rem;
    top: 50%;
    width: 17px;
    height: 17px;
    flex-shrink: 0;
    color: rgba(18, 10, 42, 0.72);
    transform: translateY(-50%);
}

.bf-code .bf-check-icon {
    display: none;
}

.bf-code.bf-copied {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        0 0 0 2px rgba(110, 231, 183, 0.55),
        0 12px 32px rgba(16, 185, 129, 0.28);
}

.bf-code.bf-copied .bf-copy-icon {
    display: none;
}

.bf-code.bf-copied .bf-check-icon {
    display: block;
    color: #0b5f3f;
}

/* ── Countdown + validity ────────────────────────────────────── */
.bf-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.38rem;
}

.bf-timer {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.bf-live-dot {
    width: 6px;
    height: 6px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--bf-pink);
    box-shadow: 0 0 11px rgba(236, 72, 153, 0.85);
    animation: bf-pulse 1.8s ease-out infinite;
}

@keyframes bf-pulse {
    0% { box-shadow: 0 0 0 0 rgba(236, 72, 153, 0.5), 0 0 11px rgba(236, 72, 153, 0.85); }
    70% { box-shadow: 0 0 0 6px rgba(236, 72, 153, 0), 0 0 11px rgba(236, 72, 153, 0.85); }
    100% { box-shadow: 0 0 0 0 rgba(236, 72, 153, 0), 0 0 11px rgba(236, 72, 153, 0.85); }
}

.bf-timer-label {
    font-size: 0.66rem;
    font-weight: 600;
    color: var(--bf-muted);
}

.bf-clock {
    display: flex;
    align-items: center;
    gap: 3px;
}

.bf-seg {
    display: inline-flex;
    align-items: baseline;
    gap: 1px;
    padding: 2px 5px;
    border: 1px solid rgba(196, 181, 253, 0.16);
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.06);
}

.bf-seg b {
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
    letter-spacing: 0.02em;
}

.bf-seg i {
    font-style: normal;
    font-size: 0.46rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bf-lavender);
}

.bf-valid {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    font-size: 0.7rem;
    color: var(--bf-muted);
}

.bf-valid svg {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
    color: var(--bf-lavender);
}

/* ── Utility / focus ─────────────────────────────────────────── */
.bf-code:focus-visible {
    outline: 2px solid var(--bf-lavender);
    outline-offset: 3px;
}

.bf-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ── Responsive ──────────────────────────────────────────────── */

/* Tablet: stack the three zones */
@media (max-width: 920px) {
    .bf-inner {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 0.65rem;
        padding: 1.4rem 2rem 1.45rem;
    }

    .bf-action {
        flex-direction: row;
        justify-content: center;
        width: 100%;
        gap: 0.5rem;
    }

    .bf-code {
        width: min(300px, 60%);
    }

    .bf-meta {
        flex-direction: row;
        align-items: center;
        justify-content: center;
        gap: 0.8rem;
    }

    .bf-lead .bf-ring {
        width: 128px;
        height: 128px;
    }
}

/* Phone */
@media (max-width: 640px) {
    .bf-overlay {
        top: 68px;
        width: 100%;
        border-radius: 0;
    }

    .bf-inner {
        gap: 0.5rem;
        padding: 1.05rem 1rem 1.1rem;
    }

    .bf-kicker {
        font-size: 0.7rem;
    }

    .bf-percent {
        font-size: 2.9rem;
    }

    .bf-rabatt {
        font-size: 0.9rem;
        letter-spacing: 0.14em;
    }

    .bf-sub {
        font-size: 0.76rem;
    }

    .bf-lead .bf-ring {
        width: 112px;
        height: 112px;
    }

    .bf-code {
        width: min(210px, 64%);
        padding: 0.5rem 2.2rem;
    }

    .bf-code-label {
        font-size: 0.55rem;
    }

    .bf-code-value {
        font-size: 0.92rem;
    }

    .bf-code svg {
        right: 0.7rem;
        width: 15px;
        height: 15px;
    }

    .bf-meta {
        flex-direction: column;
        gap: 0.2rem;
    }

    .bf-timer {
        gap: 0.3rem;
    }

    .bf-timer-label {
        font-size: 0.62rem;
    }

    .bf-seg {
        padding: 2px 4px;
    }

    .bf-seg b {
        font-size: 0.68rem;
    }

    .bf-seg i {
        font-size: 0.44rem;
    }

    .bf-valid {
        font-size: 0.66rem;
    }
}

/* Very narrow phones */
@media (max-width: 340px) {
    .bf-code {
        width: 100%;
        max-width: 250px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bf-overlay {
        animation: none;
    }

    .bf-code {
        transition: none;
    }

    .bf-live-dot {
        animation: none;
    }
}

/* If mask gradients are unavailable, hide the ring rather than
   painting a filled gradient disc behind the content. */
@supports not ((mask-image: radial-gradient(#000, #000)) or (-webkit-mask-image: radial-gradient(#000, #000))) {
    .bf-lead .bf-ring {
        display: none;
    }
}

@media print {
    .bf-overlay {
        display: none !important;
    }
}
