/**
 * CTA (Call To Action) Buttons - Sticky & Prominent
 * כפתורים בולטים של "התקשר עכשיו" ו"וואטסאפ"
 */

/* ========================================
   STICKY TOP BAR CTA
   ======================================== */

.cta-top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #212121 0%, #1a1a1a 100%);
    padding: 12px 0;
    z-index: 10000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.cta-top-bar.visible {
    transform: translateY(0);
}

.cta-top-bar .container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

.cta-top-bar .cta-message {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
}

.cta-top-bar .cta-buttons {
    display: flex;
    gap: 12px;
}

.cta-btn-call,
.cta-btn-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.cta-btn-call {
    background: #fff;
    color: #212121;
    border-color: #fff;
}

.cta-btn-call:hover {
    background: transparent;
    color: #fff;
    border-color: #fff;
    transform: scale(1.05);
}

.cta-btn-whatsapp {
    background: rgba(255,255,255,0.2);
    color: #fff;
    border-color: rgba(255,255,255,0.5);
    backdrop-filter: blur(10px);
}

.cta-btn-whatsapp:hover {
    background: #fff;
    color: #212121;
    border-color: #fff;
    transform: scale(1.05);
}

.cta-btn-call i,
.cta-btn-whatsapp i {
    font-size: 20px;
}

/* Close button */
.cta-close-btn {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.cta-close-btn:hover {
    opacity: 1;
}

/* ========================================
   FLOATING SIDE BUTTONS
   ======================================== */

.cta-floating-buttons {
    position: fixed;
    left: 20px;
    bottom: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Social Media Buttons (Right Side) */
.cta-social-buttons {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 15px;
    animation: slideInRight 0.6s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.cta-floating-btn {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 6px 25px rgba(0,0,0,0.3);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    position: relative;
    animation: pulse-glow 2s infinite;
    border: 3px solid rgba(255,255,255,0.3);
}

.cta-floating-btn:hover {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 8px 35px rgba(0,0,0,0.4);
    animation: none;
}

.cta-floating-btn i {
    font-size: 32px;
    color: #fff;
}

.cta-floating-btn.whatsapp {
    background: linear-gradient(135deg, #212121 0%, #1a1a1a 100%);
}

.cta-floating-btn.phone {
    background: linear-gradient(135deg, #212121 0%, #1a1a1a 100%);
}

.cta-floating-btn.emergency {
    background: linear-gradient(135deg, #f44336 0%, #da190b 100%);
    animation: pulse-emergency 1.5s infinite;
}

.cta-floating-btn.tiktok {
    background: linear-gradient(135deg, #000000 0%, #EE1D52 50%, #69C9D0 100%);
    width: 60px;
    height: 60px;
    animation: pulse-social 2.5s infinite;
}

.cta-floating-btn.instagram {
    background: linear-gradient(135deg, #833AB4 0%, #FD1D1D 50%, #F77737 100%);
    width: 60px;
    height: 60px;
    animation: pulse-social 2.5s infinite 0.3s;
}

@keyframes pulse-social {
    0%, 100% {
        box-shadow: 0 6px 25px rgba(0,0,0,0.3);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 8px 35px rgba(131, 58, 180, 0.6);
        transform: scale(1.05);
    }
}

/* Tooltip */
.cta-floating-btn::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 85px;
    background: #2c2c2c;
    color: #fff;
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    transform: translateX(-10px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.cta-floating-btn:hover::after {
    opacity: 1;
    transform: translateX(0);
}

/* Tooltip for social buttons (right side) - appears on left */
.cta-social-buttons .cta-floating-btn::after {
    right: auto;
    left: 85px;
    transform: translateX(10px);
}

.cta-social-buttons .cta-floating-btn:hover::after {
    transform: translateX(0);
}

/* Pulse animations */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 6px 25px rgba(0,0,0,0.3);
    }
    50% {
        box-shadow: 0 8px 35px rgba(0, 0, 0, 0.6);
    }
}

@keyframes pulse-emergency {
    0%, 100% {
        box-shadow: 0 6px 25px rgba(244, 67, 54, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 10px 40px rgba(244, 67, 54, 0.8);
        transform: scale(1.05);
    }
}

/* Badge (notification dot) */
.cta-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff0000;
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    border: 2px solid #fff;
    animation: badge-pulse 2s infinite;
}

@keyframes badge-pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

/* ========================================
   STICKY BOTTOM BAR (Mobile)
   ======================================== */

.cta-bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(44, 44, 44, 0.98), rgba(44, 44, 44, 0.95));
    padding: 15px 20px;
    z-index: 9998;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
    display: none; /* Show only on mobile */
}

.cta-bottom-bar .cta-buttons-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    max-width: 600px;
    margin: 0 auto;
}

.cta-bottom-bar .cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cta-bottom-bar .cta-btn-call {
    background: #212121;
    color: #fff;
}

.cta-bottom-bar .cta-btn-whatsapp {
    background: #212121;
    color: #fff;
}

.cta-bottom-bar .cta-btn:active {
    transform: scale(0.95);
}

.cta-bottom-bar .cta-btn i {
    font-size: 22px;
}

/* ========================================
   FULL SCREEN CTA OVERLAY
   ======================================== */

.cta-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 20000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.cta-overlay.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.cta-overlay-content {
    background: #fff;
    padding: 50px;
    border-radius: 20px;
    text-align: center;
    max-width: 500px;
    box-shadow: 0 10px 50px rgba(0,0,0,0.5);
    animation: slideUp 0.4s ease;
}

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

.cta-overlay-content h2 {
    font-size: 32px;
    color: #2c2c2c;
    margin-bottom: 15px;
}

.cta-overlay-content p {
    font-size: 18px;
    color: #666;
    margin-bottom: 30px;
}

.cta-overlay-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cta-overlay-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 18px 30px;
    border-radius: 12px;
    font-size: 20px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cta-overlay-btn.call {
    background: #212121;
    color: #fff;
}

.cta-overlay-btn.whatsapp {
    background: #212121;
    color: #fff;
}

.cta-overlay-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

.cta-overlay-close {
    margin-top: 20px;
    background: transparent;
    border: none;
    color: #999;
    font-size: 16px;
    cursor: pointer;
    text-decoration: underline;
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
    /* Hide floating buttons on mobile (use bottom bar instead) */
    .cta-floating-buttons {
        display: none;
    }

    /* Keep social buttons visible but smaller on mobile */
    .cta-social-buttons {
        right: 10px;
        bottom: 80px; /* Move up to avoid bottom bar */
        gap: 10px;
    }

    .cta-social-buttons .cta-floating-btn {
        width: 50px !important;
        height: 50px !important;
    }

    .cta-social-buttons .cta-floating-btn i {
        font-size: 24px;
    }

    /* Show bottom bar on mobile */
    .cta-bottom-bar {
        display: block;
    }

    /* Adjust top bar for mobile */
    .cta-top-bar .container {
        flex-direction: column;
        gap: 10px;
    }

    .cta-top-bar .cta-message {
        font-size: 14px;
        text-align: center;
    }

    .cta-btn-call,
    .cta-btn-whatsapp {
        font-size: 14px;
        padding: 10px 18px;
    }

    /* Overlay content */
    .cta-overlay-content {
        padding: 30px;
        margin: 20px;
    }

    .cta-overlay-content h2 {
        font-size: 24px;
    }

    .cta-overlay-content p {
        font-size: 16px;
    }

    .cta-overlay-btn {
        font-size: 18px;
        padding: 15px 25px;
    }
}

@media (max-width: 480px) {
    .cta-bottom-bar .cta-buttons-row {
        grid-template-columns: 1fr;
    }

    .cta-overlay-content {
        padding: 25px;
    }
}

/* ========================================
   PRINT STYLES (hide CTAs when printing)
   ======================================== */

@media print {
    .cta-top-bar,
    .cta-floating-buttons,
    .cta-social-buttons,
    .cta-bottom-bar,
    .cta-overlay {
        display: none !important;
    }
}
