/* Freelancer Profile Modal */
.modal {
    display: none; 
    position: fixed; 
    z-index: 1000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.6); 
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: #ffffff;
    margin: 3% auto; 
    padding: 30px;
    border: 1px solid #ddd;
    width: 90%; 
    max-width: 800px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    animation: slideDown 0.4s ease;
    max-height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
}

@keyframes slideDown {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.close-modal-btn {
    color: #888;
    float: right;
    font-size: 28px;
    font-weight: bold;
    transition: all 0.2s ease;
    position: absolute;
    top: 15px;
    right: 25px;
    z-index: 1001;
    height: 40px;
    width: 40px;
    text-align: center;
    line-height: 38px;
    border-radius: 50%;
    background: rgba(255,255,255,0.7);
}

.close-modal-btn:hover,
.close-modal-btn:focus {
    color: #333;
    background: #ffffff;
    text-decoration: none;
    cursor: pointer;
    transform: scale(1.1);
    box-shadow: 0 3px 10px rgba(0,0,0,0.15);
}

/* Profile Header */
.profile-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9ecef;
}

.profile-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 25px;
    border: 4px solid #f8f9fa;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.profile-photo:hover {
    transform: scale(1.05);
}

.profile-photo-placeholder {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin-right: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.profile-photo-placeholder:hover {
    transform: scale(1.05);
}

.profile-header-info {
    flex-grow: 1;
    padding-top: 8px;
}

.profile-header-info h2 {
    margin: 0;
    font-size: 2em;
    color: #333;
    font-weight: 600;
    line-height: 1.2;
}

.profile-header-info .headline {
    font-size: 1.2em;
    color: #6c757d;
    margin: 8px 0;
    font-weight: 500;
}

.meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 12px;
}

.meta-info p {
    margin: 0;
    font-size: 0.95em;
    color: #666;
    display: flex;
    align-items: center;
}

.meta-info i {
    margin-right: 6px;
    opacity: 0.8;
}

.location {
    display: flex;
    align-items: center;
}

.availability {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 500;
}

.availability.available {
    background-color: rgba(52, 199, 89, 0.15);
    color: #28a745;
}

.availability.busy, 
.availability.unavailable {
    background-color: rgba(255, 59, 48, 0.15);
    color: #dc3545;
}

.rate {
    font-weight: 600;
    color: #495057;
}

.modal-rating {
    display: flex;
    align-items: center;
    margin-top: 10px;
    gap: 8px;
}

.modal-rating .stars {
    display: flex;
    gap: 3px;
}

.modal-rating .star {
    color: #FFD700;
    font-size: 16px;
    text-shadow: 0 1px 1px rgba(0,0,0,0.1);
}

.modal-rating .star.empty {
    color: #e0e0e0;
}

.modal-rating .rating-value {
    font-weight: 600;
    color: #495057;
    margin-left: 5px;
}

.identity-verified {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(52, 199, 89, 0.1);
    color: #28a745;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.identity-verified i {
    color: #28a745;
}

/* Contact Section */
.contact-section {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
    margin-bottom: 25px;
}

.contact-buttons {
    display: flex;
    gap: 10px;
    margin-right: 10px;
}

.btn-whatsapp, .btn-call, .btn-email {
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: #fff;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
}

.btn-whatsapp i, .btn-call i, .btn-email i {
    margin-right: 8px;
    font-size: 16px;
}

.btn-whatsapp {
    background-color: #25D366;
}

.btn-whatsapp:hover {
    background-color: #1fb959;
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(37, 211, 102, 0.3);
}

.btn-call {
    background-color: #34B7F1;
}

.btn-call:hover {
    background-color: #23a7e3;
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(52, 183, 241, 0.3);
}

.btn-email {
    background-color: #6c757d;
}

.btn-email:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(108, 117, 125, 0.3);
}

/* View Profile Button Styles */
.btn-view-profile {
    background-color: #f8f9fa;
    color: #2d7afa;
    border: 1px solid #2d7afa;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-view-profile:hover {
    background-color: #2d7afa;
    color: white;
}

.freelancer-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.freelancer-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

@media (max-width: 576px) {
    .freelancer-card-footer {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .freelancer-actions {
        width: 100%;
        margin-top: 10px;
    }
    
    .btn-view-profile, .contact-btn {
        flex: 1;
    }
}

/* Profile Sections */
.profile-section {
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid #e9ecef;
}

.profile-section h3 {
    color: #333;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.2em;
    font-weight: 600;
    position: relative;
    padding-bottom: 10px;
}

.profile-section h3:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Bio text */
.bio-text {
    line-height: 1.6;
    color: #495057;
    margin-bottom: 0;
}

/* Skills Section */
.skills-section {
    margin-top: 10px;
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.skill-chip {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    color: #667eea;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    display: inline-block;
    transition: all 0.2s ease;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.skill-chip:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
}

/* Languages List */
.languages-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.language-item {
    background-color: #f8f9fa;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.9em;
    color: #495057;
}

/* Services List */
.services-list {
    padding-left: 0;
    list-style-type: none;
    margin-top: 15px;
}

.services-list li {
    padding: 10px 0;
    border-bottom: 1px dashed #e9ecef;
    color: #495057;
    display: flex;
    align-items: center;
}

.services-list li:last-child {
    border-bottom: none;
}

.services-list li i {
    color: #667eea;
    margin-right: 10px;
    font-size: 0.9em;
}

/* Pricing Section */
.pricing-section {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-top: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.pricing-table {
    display: grid;
    gap: 15px;
    margin-top: 10px;
}

.pricing-item {
    background-color: #fff;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
    transition: all 0.3s ease;
}

.pricing-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.service-name {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.service-price {
    color: #667eea;
    font-weight: 700;
    font-size: 1.1em;
    margin-bottom: 8px;
}

.service-description {
    color: #6c757d;
    font-size: 0.9em;
    line-height: 1.5;
}

/* Portfolio Gallery */
.portfolio-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.portfolio-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    aspect-ratio: 1 / 1;
}

.portfolio-item:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.portfolio-image-link {
    display: block;
    height: 100%;
    position: relative;
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.portfolio-overlay span {
    color: #fff;
    font-weight: 500;
    font-size: 0.9em;
    display: flex;
    align-items: center;
    gap: 5px;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-item:hover .portfolio-image {
    transform: scale(1.1);
}

/* Certifications List */
.certifications-list {
    padding-left: 0;
    list-style-type: none;
}

.certifications-list li {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 12px;
    border-left: 4px solid #667eea;
}

.certification-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.certification-issuer,
.certification-date {
    font-size: 0.9em;
    color: #6c757d;
    margin-bottom: 3px;
}

/* Experience List */
.experience-list {
    padding-left: 0;
    list-style-type: none;
}

.experience-item {
    position: relative;
    padding-left: 25px;
    padding-bottom: 20px;
    border-left: 2px solid #e9ecef;
    margin-left: 10px;
}

.experience-item:before {
    content: '';
    position: absolute;
    left: -10px;
    top: 0;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    border: 2px solid #667eea;
}

.experience-item:last-child {
    border-left: 2px solid transparent;
    padding-bottom: 0;
}

.experience-header {
    font-size: 1.05em;
    margin-bottom: 5px;
}

.company-name {
    color: #667eea;
}

.experience-period {
    font-size: 0.9em;
    color: #6c757d;
    margin-bottom: 8px;
}

.experience-description {
    color: #495057;
    line-height: 1.5;
    font-size: 0.95em;
    margin-top: 8px;
}

/* Education List */
.education-list {
    padding-left: 0;
    list-style-type: none;
}

.education-item {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 12px;
    transition: all 0.2s ease;
}

.education-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.education-degree {
    margin-bottom: 5px;
}

.education-degree strong {
    color: #333;
}

.education-details {
    font-size: 0.9em;
    color: #6c757d;
}

/* Reviews Section */
.reviews-section {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 10px;
}

.review-item {
    background-color: #fff;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.review-author {
    font-weight: 600;
    color: #333;
}

.review-rating {
    color: #FFD700;
}

.review-date {
    font-size: 0.8em;
    color: #adb5bd;
    margin-bottom: 10px;
}

.review-text {
    color: #495057;
    line-height: 1.6;
    font-size: 0.95em;
}

.show-more-reviews {
    text-align: center;
    padding: 10px;
    margin-top: 10px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 8px;
    color: #667eea;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.show-more-reviews:hover {
    background: rgba(102, 126, 234, 0.2);
}

/* Media Queries for Responsive Design */
@media (max-width: 768px) {
    .profile-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .profile-photo,
    .profile-photo-placeholder {
        margin-right: 0;
        margin-bottom: 20px;
    }
    
    .identity-verified {
        position: static;
        margin-top: 15px;
        justify-content: center;
    }
    
    .meta-info {
        justify-content: center;
    }
    
    .modal-rating {
        justify-content: center;
    }
    
    .contact-section {
        justify-content: center;
    }
    
    .portfolio-gallery {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

/* FontAwesome icon fallbacks using emoji */
[class*="fas fa-"], 
[class*="fab fa-"] {
    font-style: normal;
}

.fas.fa-map-marker-alt:before {
    content: "📍";
}

.fas.fa-check-circle:before {
    content: "✓";
}

.fab.fa-whatsapp:before {
    content: "📱";
}

.fas.fa-phone:before {
    content: "📞";
}

.fas.fa-envelope:before {
    content: "✉️";
}

.fas.fa-eye:before {
    content: "👁️";
}
