/* ====================================
   Profile Selector Styles
   ==================================== */

.profile-selector-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #1e3a5f 0%, #0f172a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: var(--space-4);
}

.profile-selector-modal {
    background: white;
    border-radius: 24px;
    width: 100%;
    max-width: 400px;
    padding: var(--space-6);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    animation: slideUp 0.4s ease;
}

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

.profile-selector-header {
    text-align: center;
    margin-bottom: var(--space-6);
}

.profile-selector-header h2 {
    font-size: var(--text-2xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-2);
}

.profile-selector-header p {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

/* Profile List */
.profile-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.profile-card {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4) 1.25rem;
    border-radius: var(--radius-xl);
    cursor: pointer;
    transition: all var(--dur-base) var(--ease);
    border: 2px solid transparent;
}

.profile-card:hover {
    transform: translateX(4px);
}

/* Parent Profile - Blue */
.profile-card.parent {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-color: #bfdbfe;
}

.profile-card.parent:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.profile-card.parent .profile-avatar {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.profile-card.parent .profile-badge {
    background: #3b82f6;
    color: white;
}

/* Child Profile - Green */
.profile-card.child {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-color: #bbf7d0;
}

.profile-card.child:hover {
    border-color: #22c55e;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.2);
}

.profile-card.child .profile-avatar {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
}

.profile-card.child .profile-badge {
    background: #22c55e;
    color: white;
}

/* Add Child Profile - Purple */
.profile-card.add-child-card {
    background: linear-gradient(135deg, #faf5ff 0%, #f3e8ff 100%);
    border-color: #e9d5ff;
    text-decoration: none;
}

.profile-card.add-child-card:hover {
    border-color: #a855f7;
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.2);
}

.add-child-avatar {
    background: linear-gradient(135deg, #a855f7 0%, #9333ea 100%) !important;
    color: white !important;
}

.add-child-badge {
    background: #a855f7 !important;
    color: white !important;
}

/* Child profiles hint text */
.child-profiles-hint {
    text-align: center;
    font-size: 0.8125rem;
    color: #94a3b8;
    margin: var(--space-2) 0 var(--space-1);
    padding: 0;
    font-style: italic;
}

/* Profile Avatar */
.profile-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-xl);
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* Profile Info */
.profile-info {
    flex: 1;
    min-width: 0;
}

.profile-name {
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--space-1);
}

.profile-badge {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 600;
    padding: var(--space-1) 0.625rem;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Arrow Icon */
.profile-arrow {
    color: #94a3b8;
    transition: transform var(--dur-base);
}

.profile-card:hover .profile-arrow {
    transform: translateX(4px);
    color: var(--text-muted);
}

/* Footer */
.profile-selector-footer {
    margin-top: var(--space-5);
    text-align: center;
    padding-top: var(--space-5);
    border-top: 1px solid var(--border-color);
}

.btn-text {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    padding: var(--space-2) var(--space-4);
    transition: color var(--dur-base);
}

.btn-text:hover {
    color: #3b82f6;
}

/* Profile Indicator - Shows when using child profile */
.profile-indicator {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    padding: var(--space-2) var(--space-4);
    z-index: 9998;
    display: flex;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.profile-indicator-content {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    font-size: var(--text-sm);
    font-weight: 500;
}

.profile-indicator-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8125rem;
}

.profile-indicator-name {
    opacity: 0.95;
}

.profile-indicator-switch {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.375rem 0.875rem;
    border-radius: 50px;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--dur-base);
}

.profile-indicator-switch:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Adjust body when profile indicator is shown */
body.child-profile-active {
    padding-top: 44px;
}

body.child-profile-active .navbar,
body.child-profile-active header {
    top: 44px;
}

/* Responsive */
@media (max-width: 480px) {
    .profile-selector-modal {
        padding: var(--space-5);
        border-radius: 20px;
    }

    .profile-card {
        padding: 0.875rem var(--space-4);
    }

    .profile-avatar {
        width: 48px;
        height: 48px;
        font-size: var(--text-lg);
    }

    .profile-name {
        font-size: var(--text-base);
    }
}
