/* Jambvant - Modal Styles */

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

/* Profile Modal Styles */
.profile-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2001;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.profile-modal-overlay.active {
    display: flex;
}

.profile-modal-container {
    background-color: var(--bg-white);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    width: 380px;
    max-width: 100%;
    position: relative;
    animation: profileModalSlideIn 0.3s ease;
    overflow: hidden;
}

@keyframes profileModalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.profile-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--bg-white);
    border: none;
    font-size: 24px;
    color: var(--text-gray);
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.profile-modal-close:hover {
    background-color: var(--bg-light);
    color: var(--text-dark);
    transform: scale(1.1);
}

.profile-modal-content {
    padding: 30px;
    text-align: center;
}

.profile-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    font-weight: 700;
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.profile-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 12px;
    line-height: 1.2;
}

.profile-tier-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 16px;
}

.profile-tier-badge {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.profile-tier-badge.bronze {
    background: radial-gradient(circle at 30% 30%, #CD7F32, #8B5A3C);
}

.profile-tier-badge.silver {
    background: radial-gradient(circle at 30% 30%, #D3D3D3, #A8A9A9);
}

.profile-tier-badge.gold {
    background: radial-gradient(circle at 30% 30%, #FFD700, #FFC700);
}

.profile-tier-badge.platinum {
    background: radial-gradient(circle at 30% 30%, #E6CCFF, #B997EC);
}

.profile-tier-badge.emerald {
    background: radial-gradient(circle at 30% 30%, #7FD8BE, #50C878);
}

.profile-tier-badge.diamond {
    background: radial-gradient(circle at 30% 30%, #00BFFF, #1E90FF);
}

.profile-tier-text {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

.profile-helps {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 20px;
}

.profile-helps-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-purple);
    display: block;
    margin-bottom: 4px;
}

.profile-bio {
    font-size: 14px;
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 16px;
    padding: 0 10px;
}

.profile-location {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.profile-location::before {
    content: '📍';
    font-size: 16px;
}

.profile-connect-btn {
    width: 100%;
    padding: 14px 24px;
    background-color: #FF8C00;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(255, 140, 0, 0.3);
}

.profile-connect-btn:hover {
    background-color: #E07B00;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 140, 0, 0.4);
}

.profile-connect-btn:active {
    transform: translateY(0);
}

.profile-connect-btn.connected {
    background-color: var(--color-success);
}

/* Login/Signup Modal Styles */
.modal-container {
    background-color: var(--bg-white);
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 400px;
    max-width: 90%;
    position: relative;
    animation: modalSlideIn 0.3s ease;
}

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

.modal-header {
    padding: 24px 24px 0 24px;
    position: relative;
}

.modal-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 24px;
    text-align: center;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-gray);
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background-color: var(--bg-light);
    color: var(--text-dark);
}

.modal-tabs {
    display: flex;
    border-bottom: 2px solid #e0e0e0;
    margin: 0 24px;
}

.modal-tab {
    flex: 1;
    padding: 12px 16px;
    background: none;
    border: none;
    font-size: 16px;
    font-weight: 600;
    color: #999;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.modal-tab.active {
    color: #FF8C00;
}

.modal-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #FF8C00;
}

.modal-body {
    padding: 24px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 16px;
    color: var(--text-dark);
    background-color: var(--bg-white);
    transition: all 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 3px rgba(255, 140, 0, 0.1);
}

.form-input::placeholder {
    color: var(--text-gray);
    opacity: 0.7;
}

.btn-modal-primary {
    width: 100%;
    padding: 14px;
    background-color: #FF8C00;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 8px;
}

.btn-modal-primary:hover:not(:disabled) {
    background-color: #E07B00;
    transform: translateY(-1px);
}

.btn-modal-primary:disabled {
    background-color: #CCC;
    cursor: not-allowed;
    opacity: 0.6;
}

.input-with-audio {
    position: relative;
}

.audio-record-btn {
    position: absolute;
    right: 8px;
    top: 8px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--primary);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.audio-record-btn:hover {
    background: #4a3bc7;
    transform: scale(1.05);
}

.audio-record-btn.recording {
    background: #FF4444;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 68, 68, 0.7);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(255, 68, 68, 0);
    }
}

.audio-record-btn.processing {
    background: #FFA500;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.form-input.with-audio {
    padding-right: 45px;
}

textarea.form-input.with-audio {
    padding-right: 50px;
}

.error-message {
    color: #FF4444;
    font-size: 14px;
    margin-top: 4px;
    display: none;
}

.error-message.show {
    display: block;
}

.divider {
    display: flex;
    align-items: center;
    margin: 24px 0;
    color: var(--text-gray);
    font-size: 14px;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: #e0e0e0;
}

.divider::before {
    margin-right: 12px;
}

.divider::after {
    margin-left: 12px;
}

.btn-google {
    width: 100%;
    padding: 12px;
    background-color: white;
    border: 1px solid #DDD;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.2s ease;
}

.btn-google:hover {
    background-color: var(--bg-light);
    border-color: #999;
}

.google-icon {
    width: 20px;
    height: 20px;
}

/* Responsive Design */
@media (max-width: 480px) {
    .profile-modal-container {
        width: 100%;
        max-width: 340px;
    }

    .profile-modal-content {
        padding: 24px 20px;
    }

    .profile-avatar {
        width: 80px;
        height: 80px;
        font-size: 30px;
    }

    .profile-name {
        font-size: 20px;
    }

    .profile-helps-number {
        font-size: 24px;
    }

    .modal-container {
        width: 90%;
    }

    .modal-title {
        font-size: 20px;
    }

    .modal-body {
        padding: 20px;
    }
}

