/* CSS Variables for Animations */
:root {
    --primary-color: #06C755;
    --accent-color: #FFD700;
}

/* ----------------------------------------------------
   Floating Coins Animation
   ---------------------------------------------------- */
.floating-coins {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.floating-coins .coin {
    position: absolute;
    width: 60px;
    height: 60px;
    background: var(--accent-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 30px;
    color: #B8860B;
    box-shadow: inset -2px -2px 10px rgba(0, 0, 0, 0.2), 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 4px solid #FFED4D;
    z-index: 1;
    animation: floatCoin 3s ease-in-out infinite;
}

.c1 {
    top: 15%;
    left: 10%;
    animation-delay: 0s;
}

.c2 {
    top: 25%;
    right: 15%;
    animation-delay: 1s;
    width: 40px;
    height: 40px;
    font-size: 20px;
}

.c3 {
    bottom: 20%;
    left: 15%;
    animation-delay: 2s;
    width: 50px;
    height: 50px;
    font-size: 24px;
}

.c4 {
    bottom: 10%;
    right: 5%;
    animation-delay: 0.5s;
}

@keyframes floatCoin {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(10deg);
    }
}

@media (max-width: 600px) {
    .coin.c1 {
        left: -10px !important;
        top: 15% !important;
        opacity: 0.8;
    }

    .coin.c2 {
        right: -10px !important;
        top: 45% !important;
        left: auto !important;
        opacity: 0.8;
    }

    .coin.c3,
    .coin.c4 {
        display: none;
    }
}


/* ----------------------------------------------------
   Phone Mockup & Dynamic Demo
   ---------------------------------------------------- */
.phone-mockup {
    width: 300px;
    height: 600px;
    background: #fff;
    border-radius: 40px;
    padding: 10px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    border: 8px solid #333;
    position: relative;
    margin: 0 auto;
    /* Ensure it sits above background but respects parent layout */
    z-index: 10;
}

/* Adjust for existing responsiveness */
@media (max-width: 768px) {
    .phone-mockup {
        width: 260px;
        height: 520px;
        margin-top: 20px;
        border-width: 5px;
        border-radius: 30px;
    }
}

@media (max-width: 600px) {
    .phone-mockup {
        width: 240px;
        height: 480px;
    }
}

.screen {
    width: 100%;
    height: 100%;
    background: #f0f2f5;
    border-radius: 32px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.chat-app {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-top: 50px;
}

.message {
    padding: 10px 15px;
    border-radius: 15px;
    font-size: 14px;
    max-width: 80%;
    position: relative;
    animation: popIn 0.5s ease backwards;
    /* Text styling reset for messages */
    color: #333;
    line-height: 1.4;
}

.message.received {
    align-self: flex-start;
    background: #fff;
    border-bottom-left-radius: 4px;
}

.message.sent {
    align-self: flex-end;
    background: var(--primary-color);
    color: #fff;
    border-bottom-right-radius: 4px;
}

.keyboard-area {
    background: #d1d5db;
    padding: 10px;
    position: relative;
}

.keyboard-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 5px;
    margin-bottom: 20px;
}

.keyboard-grid span {
    background: #fff;
    height: 35px;
    border-radius: 5px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    /* Simple Animation for key taps */
    animation: keyTap 2s infinite;
}

.keyboard-grid span:nth-child(3n) {
    animation-delay: 0.2s;
}

.keyboard-grid span:nth-child(5n) {
    animation-delay: 0.5s;
}

.keyboard-grid span:nth-child(7n) {
    animation-delay: 0.8s;
}

.points-indicator {
    position: absolute;
    top: -40px;
    right: 20px;
    background: var(--accent-color);
    color: #333;
    font-weight: 800;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    opacity: 0;
    transform: translateY(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

@keyframes popIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

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

@keyframes keyTap {

    0%,
    100% {
        transform: scale(1);
        background: #fff;
    }

    50% {
        transform: scale(0.95);
        background: #eee;
    }
}


/* ----------------------------------------------------
   Sticky CTA
   ---------------------------------------------------- */
.sticky-cta {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    width: 90%;
    max-width: 600px;
    background: rgba(30, 30, 30, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    padding: 15px 25px;
    z-index: 999;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    /* Ensure content is visible */
    color: #fff;
    display: block;
    /* Force block to override any hidden states if conflict */
}

.sticky-cta.visible {
    transform: translateX(-50%) translateY(0);
}

.cta-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cta-text {
    display: flex;
    flex-direction: column;
}

.cta-label {
    background: var(--accent-color);
    color: #000;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 4px;
    display: inline-block;
    align-self: flex-start;
    margin-bottom: 2px;
}

.cta-slogan {
    color: #fff;
    font-weight: 700;
    font-size: 14px;
}

.cta-btn {
    background: var(--primary-color);
    color: #fff;
    font-weight: 700;
    padding: 10px 24px;
    border-radius: 30px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(6, 199, 85, 0.4);
    transition: transform 0.2s;
    text-decoration: none;
    /* Reset anchor style */
}

.cta-btn:hover {
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .sticky-cta {
        padding: 12px 20px;
        bottom: 15px;
    }

    .cta-slogan {
        font-size: 12px;
    }

    .cta-btn {
        padding: 8px 16px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .sticky-cta {
        padding: 15px;
        border-radius: 30px;
        width: 85%;
    }

    .cta-content {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .cta-text {
        align-items: center;
    }

    .cta-label {
        align-self: center;
        margin-bottom: 5px;
    }

    .cta-slogan {
        font-size: 16px;
        /* Slightly larger for readability in stack */
    }

    .cta-btn {
        width: 100%;
        justify-content: center;
        padding: 12px 0;
        font-size: 16px;
    }
}

@media (max-width: 600px) {
    .sticky-cta {
        padding: 15px;
        border-radius: 30px;
        width: 85%;
        bottom: 25px;
    }

    .cta-content {
        flex-direction: column !important;
        gap: 12px;
        text-align: center;
    }

    .cta-text {
        align-items: center !important;
        width: 100%;
    }

    .cta-label {
        align-self: center !important;
        margin-bottom: 8px;
    }

    .cta-slogan {
        font-size: 16px;
    }

    .cta-btn {
        width: 100%;
        justify-content: center;
        padding: 14px 0;
        font-size: 16px;
    }

    footer {
        padding-bottom: 200px !important;
    }
}