/* Profile Modal Styles */
.modal-profile {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.modal-profile.active {
    opacity: 1;
    visibility: visible;
}

.profile-modal-content {
    background: linear-gradient(135deg, #042878, #0a9bf4);
    width: 90%;
    max-width: 500px;
    border-radius: 15px;
    padding: 30px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    color: white;
    overflow: hidden;
}

.close-profile-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: #45424b;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    cursor: pointer;
    transition: background-color 0.3s;
    z-index: 1100;
}

.close-profile-modal:hover {
    background: rgba(255, 255, 255, 0.4);
}

.profile-logo {
    text-align: center;
    margin-bottom: 5px;
}

.logo-profile {
    height: 55px;
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.2));
}

.profile-title {
    font-size: 28px;
    text-align: center;
    margin-bottom: 10px;
    font-weight: 600;
}

.profile-description {
    text-align: center;
    margin-bottom: 30px;
    font-size: 16px;
    opacity: 0.9;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Photo Upload Styles */
.photo-upload-section {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.photo-preview {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
    margin-bottom: 2px;
    border: 3px solid rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: transform 0.2s ease;
}

/* Photo error state */
.photo-preview.photo-error {
    border: 3px solid #f2544c !important;
    background-color: rgba(255, 59, 48, 0.05) !important;
}

.photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-preview:hover {
    transform: scale(1.05);
}

.photo-preview:active {
    transform: scale(0.95);
}

.upload-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.upload-overlay i {
    font-size: 40px;
    color: white;
}

.photo-preview:hover .upload-overlay {
    opacity: 1;
}

.upload-button {
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    border: none;
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s;
}

.upload-button:hover {
    background: rgba(255, 255, 255, 0.3);
}

.optional-text {
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    margin: 4px 0;
}

/* Photo error message */
.photo-error-message {
    color: #ff3b30;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    margin-top: -10px;
    margin-bottom: 15px;
}

/* Form Fields Styles */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    margin-bottom: 10px;
}

.form-group label {
    font-size: 16px;
    font-weight: 500;
}

.input-with-prefix {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    overflow: hidden;
}

.input-prefix {
    padding: 0 15px;
    font-size: 20px;
    line-height: 45px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(0, 0, 0, 0.1);
    height: 100%;
    display: flex;
    align-items: center;
}

.input-prefix i {
    font-size: 24px;
    line-height: 45px;
}

/* Icon-specific styles */
.input-prefix .fa-star {
    color: #ffd700;
}

.input-prefix .fa-at {
    color: #ffffff;
}

.input-prefix .fa-linkedin {
    color: #ffffff;
}

.profile-input {
    flex: 1;
    padding: 12px 15px;
    background: transparent;
    border: none;
    outline: none;
    color: white;
    font-size: 18px;
}

.profile-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* Error state for input fields */
.input-with-prefix.field-error {
    border: 3px solid #f2544c !important;
    background-color: rgba(255, 59, 48, 0.05) !important;
    border-radius: 5px;
    position: relative;
}

/* Error message display */
.input-with-prefix.field-error::after {
    content: attr(data-error);
    position: absolute;
    bottom: -20px;
    left: 0;
    color: #ff3b30;
    font-size: 12px;
    font-weight: 500;
}

/* Estilo base para o select */
.profile-select {
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 5px;
    color: white;
    font-size: 16px;
    width: 100%;
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 16px;
}

.profile-select::-ms-expand {
    display: none;
}

.profile-select option {
    background-color: #0a4b9f;
    color: white;
    font-size: 16px;
    padding: 8px;
}

/* Keep only essential mobile adjustments */
@media (max-width: 768px) {
    .profile-select {
        font-size: 16px; /* Keep 16px to prevent zoom */
    }
}

/* Next Button Style */
.next-button {
    padding: 15px;
    background: white;
    color: #042878;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.next-button:hover {
    background: #042878;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* Fallback shake animation for browsers without Web Animation API */
@keyframes shakeAnimation {
    0% { transform: translateX(0); }
    20% { transform: translateX(-5px); }
    40% { transform: translateX(5px); }
    60% { transform: translateX(-5px); }
    80% { transform: translateX(5px); }
    100% { transform: translateX(0); }
}

.shake-animation {
    animation: shakeAnimation 0.3s ease-in-out;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .profile-modal-content {
        width: 95%;
        padding: 25px 20px;
    }
    
    .profile-title {
        font-size: 24px;
    }
    
    .photo-preview {
        width: 100px;
        height: 100px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .profile-modal-content {
        padding: 20px 15px;
    }
    
    .profile-title {
        font-size: 22px;
    }
    
    .profile-description {
        font-size: 14px;
    }
    
    .photo-preview {
        width: 90px;
        height: 90px;
    }
    
    .input-with-prefix.field-error::after,
    .profile-select.field-error::after {
        font-size: 11px;
    }
}