@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background-color: #f8fafc;
    /* iOS jaisa light gray */
    color: #0f172a;
    padding-bottom: 100px;
}

/* Entry Animation */
.animate-up {
    animation: slideUpFade 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUpFade {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.profile-wrapper {
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 100px);
}

.profile-card {
    background: #ffffff;
    width: 100%;
    max-width: 450px;
    border-radius: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

/* Cover & Avatar */
/* --- 1. COVER AREA (Blue Gradient) --- */
.profile-cover {
    height: 130px;
    /* Purana slate color hata kar ye mast blue gradient daal diya */
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    position: relative;
    margin-bottom: 50px;
    /* Halka sa glass effect ke liye */
    box-shadow: inset 0 -20px 20px rgba(0, 0, 0, 0.05);
}

.avatar-wrapper {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
}

.avatar {
    width: 90px;
    height: 90px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    /* Icon ka color bhi blue kar diya */
    color: #2563eb;
    /* Border ko background se match karne ke liye soft white/blue rakha hai */
    border: 4px solid #ffffff;
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.2);
}

.verified-badge {
    position: absolute;
    bottom: 5px;
    right: 0px;
    background: #10b981;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.7rem;
    border: 2px solid #ffffff;
    z-index: 5;
}

/* User Info */
.user-details {
    text-align: center;
    padding: 0 20px;
    margin-bottom: 25px;
}

.user-details h1 {
    margin: 0 0 4px 0;
    font-size: 1.5rem;
    font-weight: 700;
}

.user-details p {
    margin: 0 0 12px 0;
    color: #64748b;
    font-size: 0.9rem;
}

.user-role {
    background: #f1f5f9;
    color: #475569;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* 🚨 GUARDIANS SECTION CSS 🚨 */
.guardians-section {
    background: #f8fafc;
    margin: 0 20px 25px 20px;
    padding: 15px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 0 5px;
}

.section-header h3 {
    margin: 0;
    font-size: 1rem;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 8px;
}

.edit-btn {
    font-size: 0.85rem;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 600;
}

/* Guardian Item Styles */
/* Guardian Item Styles (FIXED) */
.guardian-item {
    display: flex;
    align-items: center;
    background: #ffffff;
    padding: 12px 15px;
    /* Thoda padding badhaya clean look ke liye */
    border-radius: 15px;
    margin-bottom: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.02);
    border: 1px solid #f1f5f9;
}

.guardian-item:last-child {
    margin-bottom: 0;
}

.g-avatar {
    width: 42px;
    height: 42px;
    /* Thoda bada kiya */
    background: #eff6ff;
    color: #3b82f6;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    font-size: 1.1rem;
    margin-right: 15px;
    flex-shrink: 0;
    /* 🚨 Avatar ko dabne se rokega */
}

.g-info {
    flex: 1;
    text-align: left;
    overflow: hidden;
    /* Text bahar na nikle */
}

.g-info h4 {
    margin: 0 0 3px 0;
    font-size: 0.95rem;
    color: #1e293b;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.g-info p {
    margin: 0;
    font-size: 0.8rem;
    color: #64748b;
}

.g-call {
    width: 42px;
    height: 42px;
    /* Avatar ke barabar size */
    background: #ecfdf5;
    color: #10b981;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    transition: 0.2s;
    flex-shrink: 0;
    /* 🚨 Icon ko perfect round rakhega, dabne nahi dega */
    margin-left: 10px;
}

.g-call:hover {
    background: #10b981;
    color: white;
}

/* Call icon ko rotate karne ke liye */
.g-call i {
    transform: rotate(90deg);
    /* 90deg se seedha ho jayega */
    transition: 0.3s ease;
}

/* 🎁 Bonus: Hover par mast ringing (bujne wala) effect */
.g-call:hover i {
    animation: ring 0.4s ease-in-out infinite alternate;
}

@keyframes ring {
    0% {
        transform: rotate(80deg);
    }

    100% {
        transform: rotate(100deg);
    }
}

/* Menu & Button */
.menu-list {
    padding: 0 20px;
    margin-bottom: 25px;
}

.menu-item {
    display: flex;
    justify-content: space-between;
    padding: 15px 5px;
    border-bottom: 1px solid #f1f5f9;
    text-decoration: none;
    color: #334155;
    font-weight: 500;
}

.menu-left i {
    width: 25px;
    color: #64748b;
}

.arrow {
    color: #cbd5e1;
    font-size: 0.9rem;
}

.logout-btn {
    width: calc(100% - 40px);
    margin: 0 20px 25px 20px;
    background: #ffffff;
    color: #ef4444;
    border: 2px solid #fee2e2;
    padding: 14px;
    font-size: 1rem;
    border-radius: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.logout-btn:hover {
    background: #fee2e2;
}

/* --- Profile Menu Item (Travel History se match karne ke liye) --- */
.profile-menu-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: all 0.2s ease;
}

.profile-menu-item:hover {
    background-color: #f8fafc;
}

.menu-left {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #475569;
    font-size: 0.95rem;
    font-weight: 500;
}

.menu-left i {
    width: 20px;
    color: #64748b;
}

/* --- Modal Base --- */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    /* Dark Blueish Blur */
    backdrop-filter: blur(4px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-content {
    background: #ffffff;
    width: 100%;
    max-width: 400px;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    animation: modalSlide 0.3s ease-out;
}

@keyframes modalSlide {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 1.1rem;
    color: #1e293b;
    margin: 0;
}

.modal-body {
    padding: 24px;
}

/* --- Form Elements --- */
.modal-form-group {
    margin-bottom: 20px;
}

.modal-form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 8px;
}

.modal-form-group input,
.modal-form-group select {
    width: 100%;
    padding: 12px 15px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    font-size: 1rem;
    transition: 0.3s;
}

.modal-form-group input:focus {
    outline: none;
    border-color: #3b82f6;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.btn-modal-save {
    width: 100%;
    padding: 14px;
    background: #10b981;
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.btn-modal-save:hover {
    background: #059669;
    transform: translateY(-1px);
}

.close-modal {
    font-size: 20px;
    cursor: pointer;
    color: #94a3b8;
    transition: 0.2s;
}

.close-modal:hover {
    color: #ef4444;
}