/* ===== ANIMATED TEXT WIDGET STYLES ===== */

.animated-text-wrapper {
    position: relative;
    overflow: hidden;
}

.animated-text {
    line-height: 1.6;
    font-size: 18px;
    opacity: 1;
}

.animated-text .char {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px);
    animation-fill-mode: forwards;
}

.animated-text .highlighted-text {
    font-weight: 600;
    position: relative;
    display: inline;
}

/* Typewriter Animation */
.animated-text .highlighted-text.typewriter {
    border-right: 2px solid transparent;
    animation: typewriterBlink 1s infinite;
}

.animated-text .highlighted-text.typewriter.typing {
    border-right-color: currentColor;
}

/* Highlight Animation */
.animated-text .highlighted-text.highlight {
    background: linear-gradient(90deg, transparent 0%, currentColor 0%, currentColor 100%, transparent 100%);
    background-size: 0% 100%;
    background-repeat: no-repeat;
    animation: highlightGrow 0.8s ease forwards;
}

/* Character Animations */
@keyframes typewriterBlink {
    0%, 50% { border-right-color: currentColor; }
    51%, 100% { border-right-color: transparent; }
}

@keyframes highlightGrow {
    from { background-size: 0% 100%; }
    to { background-size: 100% 100%; }
}

@keyframes bounceChar {
    0% { transform: translateY(20px); opacity: 0; }
    50% { transform: translateY(-5px); opacity: 0.8; }
    100% { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInChar {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== ADVANCED CARD WIDGET STYLES ===== */

.advanced-card-wrapper {
    margin-bottom: 20px;
    height: 100%; /* Force full height */
    display: flex;
}

.advanced-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
    opacity: 1; /* Always visible in editor */
    height: 100%; /* Force full height */
    display: flex;
    flex-direction: column;
    width: 100%;
}

.advanced-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* Force equal heights in grid containers */
.elementor-widget-advanced_card {
    height: 100% !important;
    display: flex !important;
}

/* Force parent containers to stretch */
.elementor-container .elementor-widget-advanced_card,
.elementor-section .elementor-widget-advanced_card,
.elementor-column .elementor-widget-advanced_card {
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Image Container - PROPERLY CONTAINED */
.card-image {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background: #f8f9fa;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 12px;
}

/* SHINE HOVER EFFECT */
.card-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.6),
        transparent
    );
    transition: left 0.5s ease;
    z-index: 2;
}

.card-image:hover::before {
    left: 100%;
}

/* Card Content */
.card-content {
    padding: 20px;
    flex-grow: 1; /* Take remaining space */
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 16px 0;
    color: #333333;
    flex-shrink: 0; /* Don't shrink title */
}

/* List Styles */
.card-list {
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* Take remaining space */
}

.card-list-item {
    display: flex;
    align-items: flex-start;
    opacity: 1; /* Always visible in editor */
    transform: translateX(0);
    transition: all 0.3s ease;
}

.card-list-item:hover {
    transform: translateX(5px);
}

.list-icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    margin-top: 2px;
    font-size: 16px;
    color: #e74c3c;
}

.list-content {
    flex: 1;
}

.list-title {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 4px 0;
    color: #2c3e50;
}

.list-description {
    font-size: 14px;
    color: #7f8c8d;
    margin: 0;
    line-height: 1.4;
}

/* Quote Styles */
.card-quote {
    font-size: 16px;
    font-style: italic;
    color: #555555;
    line-height: 1.6;
    padding: 16px 20px;
    background: rgba(231, 76, 60, 0.05);
    border-radius: 8px;
    border-left: 3px solid #e74c3c;
    margin: 0;
}

/* Text Styles */
.card-text {
    font-size: 14px;
    line-height: 1.6;
    color: #666666;
}

/* Animation Classes for Frontend Only */
.animate-fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .card-content {
        padding: 16px;
    }
    
    .card-title {
        font-size: 18px;
    }
    
    .list-title {
        font-size: 15px;
    }
}