/* Custom animations and styling for login page */

/* Modern Card Styling */
.card {
    border-radius: 15px !important;
    border: none !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    animation-delay: 300ms;
    animation-fill-mode: both;
}

.logo-card {
    animation: fadeInDown 0.8s ease-out 300ms forwards;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.03);
    transform: translateY(0);
    transition: all 0.3s ease;
    margin-bottom: 10px;
}

.logo-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

.main-logo {
    animation: logoAppear 1s ease-out 500ms forwards;
    opacity: 0;
}

.tagline-card {
    animation: fadeInUp 0.8s ease-out 1s forwards;
    background: linear-gradient(120deg, rgba(248, 70, 93, 0.03) 0%, rgba(108, 117, 125, 0.02) 100%);
    border-left: 3px solid #f8465d !important;
    opacity: 0;
}

.tagline-text {
    font-weight: 700;
    color: #495057;
    letter-spacing: 0.2px;
    animation: fadeInUp 0.8s ease-out 800ms forwards;
    opacity: 0;
}

/* Card entrance animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

/* Pulse animation for important elements */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.03);
    }
    100% {
        transform: scale(1);
    }
}

/* Apply animations to elements */
.login-card {
    animation: fadeInRight 0.8s ease-out 600ms forwards;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

.updates-card {
    animation: fadeInLeft 0.8s ease-out 600ms forwards;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

/* List item staggered animations */
.feature-list li:nth-child(1) {
    animation: fadeInUp 0.4s ease-out 700ms forwards;
    opacity: 0;
}
.feature-list li:nth-child(2) {
    animation: fadeInUp 0.4s ease-out 750ms forwards;
    opacity: 0;
}
.feature-list li:nth-child(3) {
    animation: fadeInUp 0.4s ease-out 800ms forwards;
    opacity: 0;
}
.feature-list li:nth-child(4) {
    animation: fadeInUp 0.4s ease-out 850ms forwards;
    opacity: 0;
}
.feature-list li:nth-child(5) {
    animation: fadeInUp 0.4s ease-out 900ms forwards;
    opacity: 0;
}
.feature-list li:nth-child(6) {
    animation: fadeInUp 0.4s ease-out 950ms forwards;
    opacity: 0;
}

/* Enhanced styling for the updates card */
.updates-card .card-body {
    background-color: #f8f9fa;
    border-radius: 0 0 0.25rem 0.25rem;
    overflow: visible;
    position: relative;
}

.feature-list .list-group-item {
    background-color: transparent;
    padding: 0.75rem 0.5rem;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    margin-bottom: 0;
    overflow: visible;
    display: flex;
    align-items: center;
}

.feature-list .list-group-item:hover {
    background-color: rgba(0,0,0,0.02);
    transform: translateX(5px);
}

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin-left: 10px;
    background-color: #6c757d;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    box-shadow: 0 3px 10px rgba(108, 117, 125, 0.2);
}

.updates-title {
    position: relative;
    padding-bottom: 10px;
    margin-bottom: 20px;
    color: #495057;
    font-weight: 700;
}

.updates-title:after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 3px;
    background-color: #6c757d;
}

/* Button animations */
.btn-more-info {
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.btn-more-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 117, 125, 0.2);
}

.btn-more-info:before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0%;
    height: 100%;
    background-color: #6c757d;
    transition: all 0.3s ease;
    z-index: -1;
}

.btn-more-info:hover:before {
    width: 100%;
    right: auto;
    left: 0;
}

.btn-more-info:hover {
    color: white;
}

/* V2Ray Menu Item Animation */
.v2ray-menu-item {
    position: relative;
    transition: all 0.3s ease;
    overflow: hidden;
}

.v2ray-menu-item i {
    animation: pulse 1.5s infinite;
    color: #f8465d !important;
    filter: drop-shadow(0 0 2px rgba(248, 70, 93, 0.5));
}

.v2ray-menu-item span {
    position: relative;
    z-index: 1;
}

.v2ray-menu-item:before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 3px;
    background-color: #f8465d;
    transition: all 0.3s ease;
}

.v2ray-menu-item:hover:before {
    width: 100%;
    opacity: 0.1;
}

.v2ray-menu-item span:after {
    content: 'جدید';
    position: absolute;
    top: -8px;
    right: -5px;
    background-color: #f8465d;
    color: white;
    padding: 0 6px;
    border-radius: 10px;
    font-size: 10px;
    opacity: 1;
    transform: scale(1);
    transition: all 0.3s ease;
    animation: pulse 1.5s infinite;
}

/* Enhanced Card Headers */
.enhanced-header {
    background: white;
    position: relative;
    overflow: hidden;
    height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.enhanced-header:before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background-color: rgba(248, 70, 93, 0.1);
    animation: float 8s ease-in-out infinite;
}

.enhanced-header:after {
    content: '';
    position: absolute;
    bottom: -30px;
    left: -30px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: rgba(248, 70, 93, 0.1);
    animation: float 6s ease-in-out infinite reverse;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }
    50% {
        transform: translate(20px, 20px) scale(1.2);
    }
    100% {
        transform: translate(0, 0) scale(1);
    }
}

.logo-container {
    position: relative;
    z-index: 10;
    margin-bottom: 15px;
    transform-origin: center;
    animation: logoAppear 1s ease-out forwards;
}

@keyframes logoAppear {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.card-title {
    color: #343a40;
    position: relative;
    z-index: 10;
    margin-bottom: 5px;
    font-weight: 700;
    animation: titleSlideIn 0.8s ease-out forwards;
}

@keyframes titleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-subtitle {
    color: #6c757d;
    position: relative;
    z-index: 10;
    font-size: 14px;
    animation: subtitleSlideIn 0.8s ease-out 0.2s forwards;
    opacity: 0;
}

@keyframes subtitleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.accent-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, #6c757d, #f8465d);
}

.accent-highlight {
    background: linear-gradient(135deg, #f8465d, #ff6b89);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.accent-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #f8465d;
    border-radius: 50%;
    margin: 0 5px;
    animation: pulse 1.5s infinite;
}

/* Tooltip/Popup styles - Replace with Accordion */
.feature-item {
    position: relative;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.3s ease;
    color: #343a40;
}

.feature-item:after {
    content: "\f078"; /* fa-chevron-down */
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: #6c757d;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.feature-item.active:after {
    transform: translateY(-50%) rotate(180deg);
    color: #f8465d;
}

.feature-item:hover, .feature-item.active {
    background-color: rgba(0,0,0,0.02);
    transform: translateX(5px);
}

/* Accordion Container */
.accordion-container {
    position: relative;
    overflow: visible;
}

.feature-accordion {
    height: 0;
    overflow: hidden;
    background-color: white !important;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: #444 !important;
    line-height: 1.7;
    font-size: 13px;
    text-align: justify;
    border-right: 3px solid #f8465d;
    max-height: 0;
    opacity: 0;
    margin-top: 0;
    margin-bottom: 0;
    padding: 0 20px;
    transform: translateY(-10px);
}

.feature-item.active + .feature-accordion {
    height: auto;
    max-height: 200px;
    opacity: 1;
    margin-top: 5px;
    margin-bottom: 15px;
    padding: 15px 20px;
    transform: translateY(0);
    animation: accordionOpen 0.4s forwards;
    background-color: white;
    color: #444;
}

/* Feature item animation on click */
.feature-item {
    transition: all 0.3s ease;
    border-radius: 10px;
    position: relative;
    cursor: pointer;
    color: #343a40;
}

.feature-item.active {
    background-color: rgba(248, 70, 93, 0.05);
    border-right: 3px solid #f8465d;
    padding-right: 10px !important;
}

.feature-item.active span {
    color: #6c757d;
}

/* Fix for proper accordion display - revised */
.feature-list .list-group-item {
    background-color: transparent;
    padding: 0.75rem 0.5rem;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    margin-bottom: 0;
    overflow: visible;
    display: flex;
    align-items: center;
}

/* Additional animations for accordion opening */
@keyframes accordionOpen {
    0% {
        opacity: 0;
        transform: translateY(-10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile fixes */
@media (max-width: 768px) {
    .feature-accordion {
        border-radius: 8px;
        background-color: white;
    }
    
    .card {
        margin-bottom: 15px;
    }
    
    .login-card, .updates-card {
        animation-delay: 400ms !important;
    }
    
    .feature-list li {
        animation-delay: 500ms !important;
    }
}

/* Button styles */
.btn-accent {
    background-color: #f8465d;
    border-color: #f8465d;
    color: white;
    transition: all 0.3s ease;
}

.btn-accent:hover, .btn-accent:focus, .btn-accent:active {
    background-color: #e6344b;
    border-color: #e6344b;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(248, 70, 93, 0.3);
}

.account-pages {
    margin-top: 2rem !important;
    margin-bottom: 2rem !important;
}

.my-5 {
    margin-top: 2rem !important;
    margin-bottom: 2rem !important;
}

/* Ensure all animations have proper delays */
.enhanced-header .card-title {
    animation-delay: 700ms;
}

.enhanced-header .card-subtitle {
    animation-delay: 800ms;
}

.enhanced-header .accent-bar {
    animation: fadeInUp 0.5s ease-out 900ms forwards;
    opacity: 0;
}

/* Ensure text is visible in accordion */
.feature-accordion {
    background-color: white !important;
    color: #444 !important;
}

/* Feature text styling */
.feature-text {
    transition: all 0.3s ease;
}

.feature-item.active .feature-text {
    color: #6c757d;
    font-weight: 600;
} 