/* ============================================================
   DarkBuy™ — Dark Patterns CSS
   All the manipulative UI elements
   ============================================================ */

/* ============================================================
   COOKIE BANNER SYSTEM
   ============================================================ */
.cookie-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9999;
    align-items: flex-end;
    justify-content: center;
    padding: 2rem;
}

.cookie-banner {
    background: var(--bg-card);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-xl);
    padding: 2rem 2.5rem;
    max-width: 750px;
    width: 100%;
    box-shadow: 0 -20px 80px rgba(0, 0, 0, 0.8);
    animation: slideUpBanner 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes slideUpBanner {
    from {
        opacity: 0;
        transform: translateY(60px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cookie-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.cookie-icon {
    font-size: 2rem;
}

.cookie-header h2 {
    font-size: 1.3rem;
    color: var(--text-primary);
}

.cookie-subtitle {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.cookie-text {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.btn-accept-all {
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    min-width: 200px;
}

.btn-accept-all:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
}

/* DARK PATTERN: Manage button is small, grey, hard to find */
.btn-manage {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border);
    padding: 0.8rem 1rem;
    border-radius: 50px;
    font-size: 0.72rem;
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    min-width: 150px;
}

.btn-manage:hover {
    color: var(--text-secondary);
    border-color: var(--border-bright);
}

.btn-reject-all {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border);
    padding: 0.6rem 1.25rem;
    border-radius: 50px;
    font-size: 0.75rem;
    cursor: pointer;
}

/* DARK PATTERN: Reject button even smaller and harder to see */
.btn-reject-small {
    background: transparent;
    color: #333;
    border: none;
    font-size: 0.68rem;
    cursor: pointer;
    text-decoration: underline;
    padding: 0.4rem;
}

.cookie-fine-print {
    font-size: 0.62rem;
    color: #333;
    line-height: 1.4;
}

/* Cookie detail modal */
.cookie-detail-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.cookie-detail-content {
    background: var(--bg-card);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-xl);
    padding: 2rem;
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    animation: fadeInUp 0.3s ease forwards;
}

.cookie-detail-content h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.cookie-detail-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.cookie-categories {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.cookie-cat {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.cookie-cat label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    margin-bottom: 0.25rem;
}

.cookie-cat p {
    font-size: 0.75rem;
    color: var(--text-muted);
    padding-left: 1.25rem;
}

.cookie-detail-buttons {
    display: flex;
    gap: 1rem;
    flex-direction: column;
}

/* ============================================================
   EXIT INTENT POPUP
   ============================================================ */
.exit-popup {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(12px);
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.exit-popup-content {
    background: linear-gradient(135deg, #1a0a0a, #1a0a2e);
    border: 1px solid rgba(239, 68, 68, 0.4);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    max-width: 500px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 0 80px rgba(239, 68, 68, 0.3);
    animation: boomIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes boomIn {
    from {
        opacity: 0;
        transform: scale(0.7);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.exit-popup-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    /* DARK PATTERN: close button is tiny and hard to click */
    font-size: 0.7rem;
    opacity: 0.3;
    padding: 4px;
}

.exit-popup-badge {
    display: inline-block;
    background: var(--gradient-accent);
    color: white;
    font-size: 0.75rem;
    font-weight: 900;
    padding: 4px 16px;
    border-radius: 50px;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    animation: pulse-badge 1s infinite;
}

.exit-popup-content h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.exit-popup-content p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.exit-offer {
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.exit-old-price {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-decoration: line-through;
    display: block;
    margin-bottom: 0.25rem;
}

.exit-timer {
    font-size: 3rem;
    font-weight: 900;
    color: var(--accent-red);
    font-family: 'Space Grotesk', monospace;
    letter-spacing: 4px;
}

.exit-timer-text {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.exit-guilt {
    font-size: 0.82rem !important;
    color: var(--accent-orange) !important;
    font-style: italic;
}

.btn-exit-accept {
    display: block;
    width: 100%;
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 0.75rem;
    transition: all 0.2s;
}

.btn-exit-accept:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
}

/* DARK PATTERN: Confirmshaming - refusing button makes you feel bad */
.btn-exit-refuse {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.68rem;
    cursor: pointer;
    text-decoration: underline;
    line-height: 1.4;
    opacity: 0.5;
}

.btn-exit-refuse:hover {
    opacity: 0.8;
}

/* ============================================================
   PUSH NOTIFICATION
   ============================================================ */
.push-notif {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: 340px;
    z-index: 9990;
    box-shadow: var(--shadow-card);
    transform: translateX(400px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.push-notif.slide-in {
    transform: translateX(0);
}

.push-icon {
    font-size: 1.5rem;
}

.push-notif div {
    flex: 1;
}

.push-notif strong {
    font-size: 0.85rem;
    display: block;
    margin-bottom: 2px;
}

.push-notif p {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.push-allow {
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}

/* DARK PATTERN: Push deny is barely visible */
.push-deny {
    background: none;
    border: none;
    color: #333;
    font-size: 0.7rem;
    cursor: pointer;
}

/* ============================================================
   PRODUCT CARD DARK PATTERNS
   ============================================================ */

/* Fake "trending" animation on cards */
.card-fire::after {
    content: '🔥 TENDANCE';
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--accent-red);
    color: white;
    font-size: 0.6rem;
    font-weight: 900;
    padding: 3px 8px;
    border-radius: 4px;
    letter-spacing: 1px;
    animation: pulse-badge 1s infinite;
}

/* Stock meter */
.stock-meter {
    width: 100%;
    height: 4px;
    background: var(--bg-secondary);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.stock-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-emerald), var(--accent-amber), var(--accent-red));
    border-radius: 2px;
    width: 8%;
    /* Always low stock */
}

/* Viewer pulse */
.viewer-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: var(--accent-emerald);
    border-radius: 50%;
    animation: viewerPulse 1.5s infinite;
    margin-right: 4px;
    vertical-align: middle;
}

@keyframes viewerPulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
    }

    50% {
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }
}

/* FOMO notification toast */
.fomo-toast {
    position: fixed;
    bottom: 1.5rem;
    left: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-md);
    padding: 0.75rem 1rem;
    max-width: 280px;
    z-index: 9980;
    box-shadow: var(--shadow-card);
    animation: toastSlide 0.4s ease, toastFade 0.4s ease 4.6s forwards;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.78rem;
}

@keyframes toastSlide {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes toastFade {
    to {
        opacity: 0;
        transform: translateX(-30px);
    }
}

.fomo-toast-avatar {
    width: 32px;
    height: 32px;
    background: var(--gradient-purple);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    flex-shrink: 0;
}

/* ============================================================
   CHECKOUT MULTI-STEP
   ============================================================ */
.checkout-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

.checkout-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 3rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
}

.step-item.active {
    color: var(--accent-red);
}

.step-item.done {
    color: var(--accent-emerald);
}

.step-num {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid var(--border-bright);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 800;
    flex-shrink: 0;
    transition: all 0.3s;
}

.step-item.active .step-num {
    background: var(--accent-red);
    border-color: var(--accent-red);
    color: white;
}

.step-item.done .step-num {
    background: var(--accent-emerald);
    border-color: var(--accent-emerald);
    color: white;
}

.step-connector {
    flex: 0 0 40px;
    height: 2px;
    background: var(--border);
    margin: 0 0.25rem;
}

.step-connector.done {
    background: var(--accent-emerald);
}

.checkout-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.4s ease forwards;
}

.checkout-card h2 {
    margin-bottom: 0.5rem;
}

.checkout-card .step-description {
    color: var(--text-secondary);
    font-size: 0.88rem;
    margin-bottom: 2rem;
}

/* Trick question styles */
.trick-checkbox {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem;
    margin-bottom: 0.75rem;
    transition: border-color 0.2s;
}

.trick-checkbox:hover {
    border-color: var(--border-bright);
}

.trick-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
}

.trick-label input[type="checkbox"] {
    margin-top: 2px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    accent-color: var(--accent-red);
}

.trick-label-text {
    flex: 1;
}

.trick-label-text strong {
    display: block;
    font-size: 0.88rem;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.trick-label-text span {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* DARK PATTERN: Hidden subscription option */
.hidden-sub {
    position: relative;
    overflow: hidden;
}

.hidden-sub::before {
    content: '★ RECOMMANDÉ';
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--accent-amber);
    color: black;
    font-size: 0.55rem;
    font-weight: 900;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Order summary */
.order-summary {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    position: sticky;
    top: 80px;
}

.order-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.85rem;
}

.order-line:last-child {
    border-bottom: none;
}

.order-line.total {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--text-primary);
    border-top: 2px solid var(--border-bright);
    padding-top: 1rem;
    margin-top: 0.5rem;
}

/* DARK PATTERN: Hidden fees revealed late */
.hidden-fee {
    color: var(--accent-red) !important;
    font-size: 0.75rem !important;
}

.hidden-fee::after {
    content: ' ⚠️ (nouveau)';
    font-size: 0.65rem;
}

/* Checkout navigation */
.checkout-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

/* DARK PATTERN: Back button is tiny and grey */
.btn-back {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.75rem;
    cursor: pointer;
    text-decoration: underline;
    padding: 0.5rem;
}

/* DARK PATTERN: Continue/pay button is big and prominent */
.btn-continue {
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 1rem 3rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    max-width: 350px;
}

.btn-continue:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
    box-shadow: var(--shadow-glow-red);
}

/* ============================================================
   HOMEPAGE HERO
   ============================================================ */
.hero {
    background: var(--gradient-hero);
    padding: 5rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(239, 68, 68, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--accent-red);
    font-size: 0.78rem;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 50px;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.hero h1 {
    margin-bottom: 1rem;
}

.hero h1 span {
    color: var(--accent-red);
}

.hero-sub {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 3rem;
    justify-content: center;
    flex-wrap: wrap;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.hero-stat-value {
    font-size: 2rem;
    font-weight: 900;
    display: block;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-stat-label {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* Section title */
.section-title {
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.section-title span {
    color: var(--accent-red);
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

/* Flash sale bar */
.flash-sale-bar {
    background: linear-gradient(90deg, #7c3aed, #ef4444, #f97316, #ef4444, #7c3aed);
    background-size: 400% 100%;
    animation: flashBg 3s infinite;
    padding: 1rem 2rem;
    text-align: center;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 1px;
}

@keyframes flashBg {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

/* Social proof strip */
.social-strip {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    border-top: 1px solid var(--border);
    padding: 0.75rem 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.social-strip span {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    .main-nav {
        padding: 0.75rem 1rem;
        gap: 0.75rem;
    }

    .nav-center {
        display: none;
    }

    .footer-main {
        grid-template-columns: 1fr 1fr;
    }

    .hero {
        padding: 3rem 1rem;
    }

    .checkout-container {
        padding: 1rem;
    }

    .checkout-card {
        padding: 1.5rem;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

@media (max-width: 480px) {
    .footer-main {
        grid-template-columns: 1fr;
    }

    .hero-stats {
        gap: 1.5rem;
    }

    .cookie-banner {
        padding: 1.5rem;
    }
}