/* ChildCard Component Styles */

/* Base Card Container */
.child-card-component {
    background: linear-gradient(145deg, #FFFFFF 0%, #F8FAFC 100%);
    border-radius: 20px;
    padding: 1.75rem;
    position: relative;
    overflow: visible;
    box-shadow: 0 10px 40px rgba(14, 81, 199, 0.08);
    border: 1px solid rgba(230, 233, 240, 0.5);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

/* Compact variant for dashboard */
.child-card-component.compact {
    padding: 1.25rem;
    border-radius: 16px;
}

/* Gradient top bar */
.child-card-component::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #0E51C7 0%, #7F4CB9 50%, #F6C344 100%);
    border-radius: 20px 20px 0 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.child-card-component:hover::before {
    opacity: 1;
}

.child-card-component:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 60px rgba(127, 76, 185, 0.15);
    border-color: rgba(14, 81, 199, 0.3);
}

/* Status Indicator */
.status-indicator {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 2;
}

.status-indicator.status-approved {
    background: linear-gradient(135deg, #289B87 0%, #1e7a6a 100%);
}
.status-indicator.status-pending {
    background: linear-gradient(135deg, #F6C344 0%, #f4b222 100%);
}
.status-indicator.status-needs-eval {
    background: linear-gradient(135deg, #E50000 0%, #b30000 100%);
}
.status-indicator.status-scheduled {
    background: linear-gradient(135deg, #0E51C7 0%, #7F4CB9 100%);
}

/* Card Header */
.child-card-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.compact .child-card-header {
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Avatar */
.child-avatar-wrapper {
    position: relative;
    flex-shrink: 0;
}

.child-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #0E51C7 0%, #7F4CB9 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(14, 81, 199, 0.25);
    transition: all 0.3s ease;
}

.compact .child-avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.child-card-component:hover .child-avatar {
    transform: rotate(-5deg) scale(1.05);
}

.avatar-initials {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: 0.05em;
}

.compact .avatar-initials {
    font-size: 1.2rem;
}

/* Avatar Badge */
.avatar-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 3px solid white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: white;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.avatar-badge.ready {
    background: linear-gradient(135deg, #289B87 0%, #1e7a6a 100%);
}

.avatar-badge.alert {
    background: linear-gradient(135deg, #F6C344 0%, #f4b222 100%);
}

/* Child Info */
.child-info {
    flex: 1;
    min-width: 0;
}

.child-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #071C2A;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.02em;
}

.compact .child-name {
    font-size: 1.1rem;
}

.child-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.85rem;
    color: #64748b;
    background: rgba(127, 76, 185, 0.05);
    padding: 0.25rem 0.75rem;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.meta-item:hover {
    background: rgba(14, 81, 199, 0.1);
    color: #0E51C7;
}

.meta-item i {
    font-size: 0.9rem;
    color: #7F4CB9;
}

/* Status Badge */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.75rem;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.status-badge.status-approved {
    background: rgba(40, 155, 135, 0.1);
    color: #289B87;
    border: 1px solid rgba(40, 155, 135, 0.2);
}

.status-badge.status-pending {
    background: rgba(246, 195, 68, 0.1);
    color: #F6C344;
    border: 1px solid rgba(246, 195, 68, 0.2);
}

.status-badge.status-needs-eval {
    background: rgba(229, 0, 0, 0.1);
    color: #E50000;
    border: 1px solid rgba(229, 0, 0, 0.2);
}

.status-badge.status-scheduled {
    background: rgba(14, 81, 199, 0.1);
    color: #0E51C7;
    border: 1px solid rgba(14, 81, 199, 0.2);
}

/* Stats Bar (Full) */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    margin-bottom: 1.25rem;
    padding: 1rem;
    background: rgba(127, 76, 185, 0.02);
    border-radius: 14px;
    border: 1px solid rgba(230, 233, 240, 0.5);
}

.stat-item {
    text-align: center;
}

.stat-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 1rem;
    font-weight: 700;
    color: #071C2A;
    margin-bottom: 0.5rem;
}

.stat-progress {
    width: 100%;
    height: 5px;
    background: rgba(230, 233, 240, 0.5);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 0.25rem;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #0E51C7 0%, #7F4CB9 100%);
    border-radius: 3px;
    transition: width 0.3s ease;
}

/* Quick Stats (Compact) */
.quick-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.stat-mini {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: #64748b;
    background: rgba(14, 81, 199, 0.05);
    padding: 0.35rem 0.75rem;
    border-radius: 10px;
}

.stat-mini strong {
    font-weight: 700;
    color: #071C2A;
}

.stat-mini.ready {
    background: rgba(40, 155, 135, 0.1);
    color: #289B87;
}

.stat-mini.pending {
    background: rgba(246, 195, 68, 0.1);
    color: #F6C344;
}

.stat-mini i {
    font-size: 0.9rem;
}

/* Diagnosis Section */
.diagnosis-section {
    margin-bottom: 1.25rem;
}

.diagnosis-section.compact {
    margin-bottom: 1rem;
}

.diagnosis-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(14, 81, 199, 0.1) 0%, rgba(127, 76, 185, 0.1) 100%);
    color: #0E51C7;
    padding: 0.5rem 1rem;
    border-radius: 14px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(14, 81, 199, 0.2);
    transition: all 0.2s ease;
}

.diagnosis-badge:hover {
    background: linear-gradient(135deg, rgba(14, 81, 199, 0.15) 0%, rgba(127, 76, 185, 0.15) 100%);
    transform: translateX(4px);
}

.diagnosis-badge i {
    color: #0E51C7;
}

/* Actions Section */
.child-actions-section {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.child-actions-section.compact {
    gap: 0.5rem;
}

.action-btn {
    flex: 1;
    min-width: fit-content;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.6rem 1rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.compact .action-btn {
    padding: 0.5rem 0.875rem;
    font-size: 0.8rem;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.action-btn:hover::before {
    left: 100%;
}

.action-btn i {
    font-size: 0.95rem;
}

/* Action Button Variants */
.action-primary {
    background: linear-gradient(135deg, #F6C344 0%, #f4b222 100%);
    color: #071C2A;
    box-shadow: 0 4px 12px rgba(246, 195, 68, 0.3);
}

.action-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(246, 195, 68, 0.4);
}

.action-book {
    background: linear-gradient(135deg, #289B87 0%, #1e7a6a 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(40, 155, 135, 0.3);
}

.action-book:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 155, 135, 0.4);
}

.action-complete {
    background: linear-gradient(135deg, #F6C344 0%, #f4b222 100%);
    color: #071C2A;
    box-shadow: 0 4px 12px rgba(246, 195, 68, 0.3);
}

.action-complete:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(246, 195, 68, 0.4);
}

.action-schedule {
    background: rgba(40, 155, 135, 0.05);
    color: #289B87;
    border-color: rgba(40, 155, 135, 0.2);
}

.action-schedule:hover {
    background: #289B87;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 155, 135, 0.3);
}

.action-delete {
    background: rgba(229, 0, 0, 0.05);
    color: #E50000;
    border-color: rgba(229, 0, 0, 0.2);
    padding: 0.6rem;
    flex: 0 0 auto;
    min-width: auto;
}

.action-delete:hover {
    background: #E50000;
    color: white;
    transform: translateY(-2px) rotate(-5deg);
    box-shadow: 0 4px 12px rgba(229, 0, 0, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .child-card-component {
        padding: 1.25rem;
    }

    .child-avatar {
        width: 48px;
        height: 48px;
    }

    .avatar-initials {
        font-size: 1.2rem;
    }

    .child-name {
        font-size: 1.1rem;
    }

    .stats-bar {
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
        padding: 0.75rem;
    }

    .child-actions-section {
        flex-direction: column;
    }

    .action-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .child-card-component {
        padding: 1rem;
        border-radius: 16px;
    }

    .child-card-header {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .child-info {
        text-align: center;
        width: 100%;
    }

    .child-meta {
        justify-content: center;
    }

    .stats-bar {
        grid-template-columns: 1fr;
    }

    .quick-stats {
        flex-direction: column;
    }

    .stat-mini {
        width: 100%;
        justify-content: center;
    }
}