/* ineed.now animated HTML5 banners — shared styles
 * Brand: ink #101319, paper #E8EAEF, now-orange #FF4D1F, live-green #0FA36B, order-blue #1B5CFF
 * Fonts: Manrope (display/body), IBM Plex Mono (code)
 */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; overflow: hidden; background: transparent; }
body {
    font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
    color: #E8EAEF;
    -webkit-font-smoothing: antialiased;
}

.ad {
    position: relative;
    overflow: hidden;
    background: #101319;
    border-radius: 10px;
    isolation: isolate;
}

/* Full-banner click target (sits under interactive pieces) */
.ad-link { position: absolute; inset: 0; z-index: 1; }
.ad-link:focus-visible { outline: 2px solid #FF4D1F; outline-offset: -3px; border-radius: 10px; }

/* ---------- Animated background ---------- */
.bg-grid {
    position: absolute; inset: -40px; z-index: -2;
    background-image:
        linear-gradient(rgba(232, 234, 239, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(232, 234, 239, .05) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: grid-pan 14s linear infinite;
}
@keyframes grid-pan { to { transform: translate(20px, 20px); } }

.bg-glow {
    position: absolute; z-index: -1; border-radius: 50%;
    filter: blur(28px); opacity: .55;
    animation: glow-drift 9s ease-in-out infinite alternate;
}
.bg-glow.orange { background: #FF4D1F; }
.bg-glow.blue   { background: #1B5CFF; animation-duration: 11s; animation-direction: alternate-reverse; opacity: .35; }
@keyframes glow-drift {
    0%   { transform: translate(0, 0) scale(1); }
    50%  { transform: translate(var(--dx, 30px), var(--dy, 10px)) scale(1.15); }
    100% { transform: translate(calc(var(--dx, 30px) * -.5), calc(var(--dy, 10px) * 1.5)) scale(.9); }
}

/* ---------- Logo ---------- */
.logo { font-weight: 800; letter-spacing: -.03em; color: #fff; line-height: 1; white-space: nowrap; }
.logo .dot { color: #FF4D1F; }
.logo .dot::after {
    content: ""; display: inline-block; width: .12em; height: .9em; margin-left: .06em;
    background: #FF4D1F; vertical-align: -.1em;
    animation: caret 1s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }

/* ---------- Live badge ---------- */
.live {
    display: inline-flex; align-items: center; gap: 6px;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: 10px; letter-spacing: .04em; text-transform: uppercase; color: #A8AFC2;
    white-space: nowrap;
}
.live i {
    position: relative; width: 7px; height: 7px; border-radius: 50%; background: #0FA36B; flex-shrink: 0;
}
.live i::after {
    content: ""; position: absolute; inset: 0; border-radius: 50%; background: #0FA36B;
    animation: ping 1.6s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes ping { 75%, 100% { transform: scale(2.6); opacity: 0; } }

/* ---------- Rotating headline: "I need a [___] — now." ---------- */
.headline { font-weight: 800; letter-spacing: -.02em; color: #fff; line-height: 1.1; }
.headline .now { color: #FF4D1F; }
.rotator {
    display: inline-block; position: relative; overflow: hidden;
    height: var(--rh, 1.15em); vertical-align: bottom;
}
.rotator ul { list-style: none; animation: rotate-words 15s cubic-bezier(.7, 0, .3, 1) infinite; }
.rotator li {
    height: var(--rh, 1.15em); line-height: var(--rh, 1.15em); white-space: nowrap;
    background: linear-gradient(90deg, #FF4D1F, #FF8A5C);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
/* 6 words + duplicate of the first for a seamless loop */
@keyframes rotate-words {
    0%, 13%       { transform: translateY(0); }
    16.67%, 29.67%{ transform: translateY(calc(var(--rh, 1.15em) * -1)); }
    33.33%, 46.33%{ transform: translateY(calc(var(--rh, 1.15em) * -2)); }
    50%, 63%      { transform: translateY(calc(var(--rh, 1.15em) * -3)); }
    66.67%, 79.67%{ transform: translateY(calc(var(--rh, 1.15em) * -4)); }
    83.33%, 96.33%{ transform: translateY(calc(var(--rh, 1.15em) * -5)); }
    100%          { transform: translateY(calc(var(--rh, 1.15em) * -6)); }
}

.sub { color: #A8AFC2; font-weight: 500; line-height: 1.3; }

/* ---------- Coupon ticket ---------- */
.coupon {
    position: relative; z-index: 2; overflow: hidden;
    display: flex; align-items: center; justify-content: center; gap: 8px;
    font: inherit; color: #fff; cursor: pointer;
    background: rgba(255, 77, 31, .1);
    border: 1.5px dashed #FF4D1F; border-radius: 8px;
    animation: coupon-pulse 2.2s ease-out infinite;
    transition: background .2s, transform .2s;
}
.coupon:hover { background: rgba(255, 77, 31, .2); transform: translateY(-1px); }
.coupon:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.coupon::before { /* shimmer sweep */
    content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .28), transparent);
    transform: skewX(-20deg);
    animation: shimmer 3.2s ease-in-out infinite;
}
@keyframes shimmer { 0%, 55% { left: -60%; } 100% { left: 130%; } }
@keyframes coupon-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(255, 77, 31, .45); }
    70%  { box-shadow: 0 0 0 9px rgba(255, 77, 31, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 77, 31, 0); }
}
.coupon .off {
    background: #FF4D1F; color: #fff; font-weight: 800; border-radius: 4px; white-space: nowrap;
    animation: off-pop 2.2s ease-in-out infinite;
}
@keyframes off-pop { 0%, 80%, 100% { transform: scale(1) rotate(0); } 88% { transform: scale(1.12) rotate(-4deg); } 94% { transform: scale(1.05) rotate(3deg); } }
.coupon .code {
    font-family: "IBM Plex Mono", ui-monospace, monospace; font-weight: 600;
    letter-spacing: .06em; white-space: nowrap;
}
.coupon .hint {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    color: #A8AFC2; text-transform: uppercase; letter-spacing: .06em; white-space: nowrap;
}
.coupon.copied { border-color: #0FA36B; border-style: solid; background: rgba(15, 163, 107, .15); animation: none; }
.coupon.copied .off { background: #0FA36B; }

/* ---------- CTA ---------- */
.cta {
    position: relative; z-index: 2;
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    background: #fff; color: #101319; font-weight: 800; text-decoration: none;
    border-radius: 8px; white-space: nowrap;
    transition: background .2s, color .2s, transform .2s;
}
.cta:hover, .ad:hover .cta { background: #FF4D1F; color: #fff; }
.cta:focus-visible { outline: 2px solid #FF4D1F; outline-offset: 2px; }
.cta .arrow { display: inline-block; animation: nudge 1.4s ease-in-out infinite; }
@keyframes nudge { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(4px); } }

/* ---------- Entrance ---------- */
.in { opacity: 0; animation: rise .6s cubic-bezier(.2, .8, .2, 1) forwards; }
.in.d1 { animation-delay: .1s; } .in.d2 { animation-delay: .25s; }
.in.d3 { animation-delay: .4s; } .in.d4 { animation-delay: .55s; } .in.d5 { animation-delay: .7s; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- System chips (tall formats) ---------- */
.chips { list-style: none; display: grid; gap: 5px; }
.chips li {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 11px; font-weight: 600; color: #CFD4E0;
    padding: 5px 8px; border-radius: 6px;
    background: rgba(232, 234, 239, .04); border: 1px solid rgba(232, 234, 239, .08);
    animation: chip-light 8s ease-in-out infinite;
}
.chips li span { font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: 9px; color: #7C8398; }
.chips li:nth-child(1) { animation-delay: 0s; }   .chips li:nth-child(2) { animation-delay: 1s; }
.chips li:nth-child(3) { animation-delay: 2s; }   .chips li:nth-child(4) { animation-delay: 3s; }
.chips li:nth-child(5) { animation-delay: 4s; }   .chips li:nth-child(6) { animation-delay: 5s; }
.chips li:nth-child(7) { animation-delay: 6s; }   .chips li:nth-child(8) { animation-delay: 7s; }
@keyframes chip-light {
    0%, 14%, 100% { background: rgba(232, 234, 239, .04); border-color: rgba(232, 234, 239, .08); color: #CFD4E0; }
    4%, 10%       { background: rgba(255, 77, 31, .16); border-color: rgba(255, 77, 31, .6); color: #fff; }
}

/* ---------- Reduced motion: keep a calm, still composition ---------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .in { opacity: 1; }
}
