/* ===================================
   Animated Buttons Pro - Styles
   =================================== */

/* Common Button Styles */
.abp-btn {
    position: relative;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    border: none;
    cursor: pointer;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    transition: all 0.5s ease;
    outline: none;
}

/* ===================================
   1. SPACE BUTTON (Original Style)
   =================================== */
.abp-space-btn {
    width: 13rem;
    height: 3rem;
    background-size: 300% 300%;
    backdrop-filter: blur(1rem);
    border-radius: 5rem;
    animation: abp-gradient-animation 5s ease infinite;
    border: double 4px transparent;
    background-image: linear-gradient(#212121, #212121),
        linear-gradient(137.48deg, #ffdb3b 10%, #fe53bb 45%, #8f51ea 67%, #0044ff 87%);
    background-origin: border-box;
    background-clip: content-box, border-box;
    overflow: hidden;
}

.abp-space-btn strong {
    z-index: 2;
    font-size: 12px;
    letter-spacing: 5px;
    color: #ffffff;
    text-shadow: 0 0 4px white;
    text-transform: uppercase;
}

.abp-container-stars {
    position: absolute;
    z-index: -1;
    width: 100%;
    height: 100%;
    overflow: hidden;
    transition: 0.5s;
    backdrop-filter: blur(1rem);
    border-radius: 5rem;
}

.abp-glow {
    position: absolute;
    display: flex;
    width: 12rem;
}

.abp-circle {
    width: 100%;
    height: 30px;
    filter: blur(2rem);
    animation: abp-pulse 4s infinite;
    z-index: -1;
}

.abp-circle:nth-of-type(1) {
    background: rgba(254, 83, 186, 0.636);
}

.abp-circle:nth-of-type(2) {
    background: rgba(142, 81, 234, 0.704);
}

.abp-space-btn:hover .abp-container-stars {
    z-index: 1;
    background-color: #212121;
}

.abp-space-btn:hover {
    transform: scale(1.1);
}

.abp-space-btn:active {
    border: double 4px #fe53bb;
    background-origin: border-box;
    background-clip: content-box, border-box;
    animation: none;
}

.abp-space-btn:active .abp-circle {
    background: #fe53bb;
}

.abp-stars {
    position: relative;
    background: transparent;
    width: 200rem;
    height: 200rem;
}

.abp-stars::after {
    content: "";
    position: absolute;
    top: -10rem;
    left: -100rem;
    width: 100%;
    height: 100%;
    animation: abp-star-rotate 90s linear infinite;
}

.abp-stars::after {
    background-image: radial-gradient(#ffffff 1px, transparent 1%);
    background-size: 50px 50px;
}

.abp-stars::before {
    content: "";
    position: absolute;
    top: 0;
    left: -50%;
    width: 170%;
    height: 500%;
    animation: abp-star-move 60s linear infinite;
}

.abp-stars::before {
    background-image: radial-gradient(#ffffff 1px, transparent 1%);
    background-size: 50px 50px;
    opacity: 0.5;
}

/* ===================================
   2. NEON BUTTON
   =================================== */
.abp-neon-btn {
    width: 13rem;
    height: 3rem;
    background: transparent;
    border: 2px solid #00ff88;
    border-radius: 5px;
    position: relative;
    overflow: hidden;
}

.abp-neon-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 3px;
    color: #00ff88;
    text-transform: uppercase;
    z-index: 2;
}

.abp-neon-text:nth-child(1) {
    color: transparent;
    -webkit-text-stroke: 1px #00ff88;
}

.abp-neon-text:nth-child(2) {
    color: #00ff88;
    animation: abp-neon-flicker 3s linear infinite;
}

.abp-neon-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, #00ff88, transparent);
    transition: 0.5s;
}

.abp-neon-btn:hover::before {
    left: 100%;
}

.abp-neon-btn:hover {
    box-shadow: 0 0 10px #00ff88, 0 0 20px #00ff88, 0 0 40px #00ff88;
    border-color: #00ff88;
}

/* ===================================
   3. GRADIENT BUTTON
   =================================== */
.abp-gradient-btn {
    width: 13rem;
    height: 3rem;
    background: linear-gradient(45deg, #FF6B6B, #4ECDC4, #45B7D1, #FFA07A);
    background-size: 300% 300%;
    border-radius: 50px;
    position: relative;
    animation: abp-gradient-shift 4s ease infinite;
    border: none;
}

.abp-gradient-text {
    position: relative;
    z-index: 2;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 2px;
    color: #fff;
    text-transform: uppercase;
}

.abp-gradient-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    border-radius: 50px;
    opacity: 0;
    transition: opacity 0.5s;
}

.abp-gradient-btn:hover .abp-gradient-overlay {
    opacity: 1;
    animation: abp-gradient-slide 1s linear infinite;
}

.abp-gradient-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

/* ===================================
   4. GLOW BUTTON
   =================================== */
.abp-glow-btn {
    width: 13rem;
    height: 3rem;
    background: #1a1a1a;
    border: 2px solid #8b5cf6;
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}

.abp-glow-text {
    position: relative;
    z-index: 2;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 2px;
    color: #fff;
    text-transform: uppercase;
}

.abp-glow-effect {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: radial-gradient(circle, #8b5cf6, transparent);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
    opacity: 0;
}

.abp-glow-btn:hover .abp-glow-effect {
    width: 300px;
    height: 300px;
    opacity: 0.5;
}

.abp-glow-btn:hover {
    box-shadow: 0 0 20px #8b5cf6, 0 0 40px #8b5cf6, inset 0 0 20px #8b5cf6;
    border-color: #a78bfa;
}

.abp-glow-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(transparent, #8b5cf6, transparent 30%);
    animation: abp-glow-rotate 4s linear infinite;
    opacity: 0;
}

.abp-glow-btn:hover::before {
    opacity: 1;
}

.abp-glow-btn::after {
    content: '';
    position: absolute;
    inset: 3px;
    background: #1a1a1a;
    border-radius: 8px;
}

/* ===================================
   5. CYBER BUTTON
   =================================== */
.abp-cyber-btn {
    width: 13rem;
    height: 3rem;
    background: linear-gradient(90deg, #00d4ff, #00ff88);
    border: none;
    border-radius: 0;
    clip-path: polygon(10% 0%, 100% 0%, 90% 100%, 0% 100%);
    position: relative;
    overflow: hidden;
}

.abp-cyber-text {
    position: relative;
    z-index: 2;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 3px;
    color: #000;
    text-transform: uppercase;
}

.abp-cyber-glitch {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 3px;
    color: #000;
    text-transform: uppercase;
    opacity: 0;
}

.abp-cyber-glitch:nth-child(2) {
    color: #00d4ff;
    animation: abp-cyber-glitch1 2s infinite;
}

.abp-cyber-glitch:nth-child(3) {
    color: #ff00ea;
    animation: abp-cyber-glitch2 2s infinite;
}

.abp-cyber-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    transition: 0.5s;
}

.abp-cyber-btn:hover::before {
    left: 100%;
}

.abp-cyber-btn:hover {
    box-shadow: 0 0 20px #00d4ff, 0 0 40px #00ff88;
    transform: skew(-2deg);
}

/* ===================================
   KEYFRAME ANIMATIONS
   =================================== */

@keyframes abp-gradient-animation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes abp-pulse {
    0% {
        transform: scale(0.75);
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(0, 0, 0, 0);
    }
    100% {
        transform: scale(0.75);
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
    }
}

@keyframes abp-star-move {
    from { transform: translateY(0); }
    to { transform: translateY(-135rem); }
}

@keyframes abp-star-rotate {
    from { transform: rotate(360deg); }
    to { transform: rotate(0); }
}

@keyframes abp-neon-flicker {
    0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
        text-shadow: 0 0 5px #00ff88, 0 0 10px #00ff88, 0 0 20px #00ff88, 0 0 40px #00ff88;
        opacity: 1;
    }
    20%, 24%, 55% {
        text-shadow: none;
        opacity: 0.5;
    }
}

@keyframes abp-gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes abp-gradient-slide {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

@keyframes abp-glow-rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes abp-cyber-glitch1 {
    0%, 100% {
        opacity: 0;
        transform: translate(-50%, -50%);
    }
    10%, 30%, 50%, 70%, 90% {
        opacity: 0.8;
        transform: translate(calc(-50% + 2px), calc(-50% + 2px));
    }
    20%, 40%, 60%, 80% {
        opacity: 0.8;
        transform: translate(calc(-50% - 2px), calc(-50% - 2px));
    }
}

@keyframes abp-cyber-glitch2 {
    0%, 100% {
        opacity: 0;
        transform: translate(-50%, -50%);
    }
    15%, 35%, 55%, 75%, 95% {
        opacity: 0.7;
        transform: translate(calc(-50% - 3px), calc(-50% + 3px));
    }
    25%, 45%, 65%, 85% {
        opacity: 0.7;
        transform: translate(calc(-50% + 3px), calc(-50% - 3px));
    }
}

/* Responsive Styles */
@media (max-width: 768px) {
    .abp-btn {
        width: 11rem !important;
        height: 2.5rem !important;
    }
    
    .abp-space-btn strong,
    .abp-neon-text,
    .abp-gradient-text,
    .abp-glow-text,
    .abp-cyber-text,
    .abp-cyber-glitch {
        font-size: 11px !important;
        letter-spacing: 2px !important;
    }
}
