/* ==========================================
   BRIQUERIE JPO — Popup Styles
   ========================================== */

.briq-jpo-popup-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.75);
    z-index: 99998;
    backdrop-filter: blur(5px);
    opacity: 0;
    transition: opacity 0.4s ease;
}
.briq-jpo-popup-overlay.visible {
    opacity: 1;
}

.briq-jpo-popup-container {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    z-index: 99999;
    width: 90%;
    max-width: 480px;
    background: var(--briq-popup-bg, #0a0a1a);
    border: 1px solid rgba(255, 107, 53, 0.3);
    padding: 2.5rem 2rem;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6),
                0 0 60px rgba(255, 107, 53, 0.08),
                inset 0 0 80px rgba(0, 0, 0, 0.3);
}
.briq-jpo-popup-container.visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Close button */
.briq-jpo-popup-close {
    position: absolute;
    top: 12px; right: 15px;
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    font-size: 1.8rem;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s;
    line-height: 1;
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
}
.briq-jpo-popup-close:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(255,255,255,0.5);
}

/* Corners */
.briq-popup-corner {
    position: absolute;
    width: 20px; height: 20px;
    z-index: 5;
}
.briq-popup-corner--tl { top: 8px; left: 8px; border-top: 2px solid var(--briq-popup-accent, #ff6b35); border-left: 2px solid var(--briq-popup-accent, #ff6b35); }
.briq-popup-corner--tr { top: 8px; right: 8px; border-top: 2px solid var(--briq-popup-accent, #ff6b35); border-right: 2px solid var(--briq-popup-accent, #ff6b35); }
.briq-popup-corner--bl { bottom: 8px; left: 8px; border-bottom: 2px solid var(--briq-popup-accent, #ff6b35); border-left: 2px solid var(--briq-popup-accent, #ff6b35); }
.briq-popup-corner--br { bottom: 8px; right: 8px; border-bottom: 2px solid var(--briq-popup-accent, #ff6b35); border-right: 2px solid var(--briq-popup-accent, #ff6b35); }
.briq-popup-corner { opacity: 0.4; }

/* Scan line */
.briq-popup-scanline {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 2px;
    background: linear-gradient(90deg, transparent, var(--briq-popup-accent, #ff6b35), transparent);
    z-index: 5;
    animation: briqScanDown 3s linear infinite;
    opacity: 0.3;
}
@keyframes briqScanDown {
    0% { top: 0; }
    100% { top: 100%; }
}

/* Content */
.briq-popup-content {
    text-align: center;
    position: relative;
    z-index: 6;
}

.briq-popup-delorean {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    animation: briqCarBounce 2s ease-in-out infinite;
}
@keyframes briqCarBounce {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px) rotate(-2deg); }
    75% { transform: translateX(5px) rotate(2deg); }
}

.briq-popup-badge {
    display: inline-block;
    font-family: 'Segoe UI', system-ui, sans-serif;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.3em;
    padding: 0.3rem 1rem;
    background: linear-gradient(135deg, #ffd700, #ff6b35);
    color: #000;
    margin-bottom: 1rem;
}

.briq-popup-title {
    font-family: 'Segoe UI', system-ui, sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 0.8rem;
    line-height: 1.2;
}

.briq-popup-text {
    font-family: 'Segoe UI', system-ui, sans-serif;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.65);
    font-weight: 300;
    line-height: 1.6;
    margin: 0 0 1.2rem;
}

/* Mini time circuit */
.briq-popup-circuit {
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    background: #111;
    border: 1px solid #333;
    padding: 0.5rem 1rem;
    margin-bottom: 1.2rem;
    border-radius: 4px;
}
.briq-popup-circuit-label {
    font-family: monospace;
    font-size: 0.5rem;
    color: #ff2d55;
    letter-spacing: 0.2em;
}
.briq-popup-circuit-date {
    font-family: monospace;
    font-size: 0.85rem;
    color: #ff2d55;
    text-shadow: 0 0 10px rgba(255, 45, 85, 0.5);
    letter-spacing: 0.1em;
}

/* CTA Button */
.briq-popup-btn {
    display: inline-block;
    font-family: 'Segoe UI', system-ui, sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.85rem 2rem;
    background: linear-gradient(135deg, var(--briq-popup-accent, #ff6b35), #ff2d55);
    color: #fff !important;
    text-decoration: none !important;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}
.briq-popup-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(255, 107, 53, 0.4);
    color: #fff !important;
}

.briq-popup-sub {
    font-family: monospace;
    font-size: 0.6rem;
    color: rgba(255,255,255,0.3);
    letter-spacing: 0.15em;
    margin-top: 1rem;
    text-transform: uppercase;
}

/* Responsive */
@media (max-width: 500px) {
    .briq-jpo-popup-container {
        width: 95%;
        padding: 2rem 1.2rem;
    }
    .briq-popup-title { font-size: 1.2rem; }
}
