/* Basic styles for the Zoho Integration Plugin */
#zoho-integration-container {
    border: 1px solid #ccc;
    padding: 15px;
    margin-top: 20px;
    background-color: #f9f9f9;
    border-radius: 5px;
}

#zoho-integration-container h3 {
    color: #333;
    margin-bottom: 10px;
}

#zoho-integration-container p {
    color: #666;
    font-size: 1.1em;
}

.job-id-display {
    font-weight: bold;
    color: #007bff; /* A nice blue color */
}

/* Styles for the Apply button */
#oeg-apply-button {
    display: block;
    margin-bottom: 20px;
    padding: 12px 24px;
    height: 40px;
    background-color: #204f70;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

#oeg-apply-button:hover:not(:disabled) {
    background-color: #183d5a;
}

#oeg-apply-button:disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
}

/* Login/Signup button state */
#oeg-apply-button.oeg-apply-button-login {
    background-color: #007bff;
    color: white;
    cursor: pointer;
}

#oeg-apply-button.oeg-apply-button-login:hover {
    background-color: #0056b3;
}

/* Styles for the modal overlay */
#oeg-referral-modal-overlay {
    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: 9999;
}

/* Styles for the modal content */
#oeg-referral-modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 80%;
    max-width: 900px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    max-height: 90%;
    overflow-y: auto;
}

/* Styles for the close button */
#oeg-referral-modal-content .close-button {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
}

/* Styles for popup pages container */
#oeg-popup-pages-container {
    margin-top: 20px;
    overflow: visible;
}

/* Reduce OEG Job Referrals title font size by 30% (from default browser h4 size) */
#oeg-popup-pages-container h4 {
    font-size: 15px; /* This parameter controls the font size - set to 15px */
    margin-bottom: 10px;
}

#oeg-popup-pages-container button {
    padding: 8px 15px;
    margin: 5px;
    background-color: #204f70;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

#oeg-popup-pages-container button:hover {
    background-color: #183d5a;
}

/* Styles for disclaimer container */
.oeg-disclaimer-container {
    border: 1px solid #e0e0e0;
    padding: 15px;
    margin-bottom: 20px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.oeg-disclaimer-container h5 {
    color: #dc3545;
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.1em;
}

.oeg-disclaimer-container p {
    font-size: 0.9em;
    line-height: 1.4;
    color: #4b4f58;
}

.oeg-disclaimer-container ul {
    list-style-type: decimal;
    padding-left: 10px;
    margin-left: 10px;
    margin-top: 10px;
}

.oeg-disclaimer-container li {
    margin-bottom: 8px;
    font-size: 0.9em;
    color: #4b4f58;
}

/* Styles for resume upload area */
.oeg-resume-upload-area {
    margin-bottom: 0px;
}

.oeg-resume-upload-area h5 {
    color: #333;
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.1em;
}

.oeg-resume-upload-area p {
    margin-bottom: 10px;
}

/* Styles for job information box */
.oeg-job-info-box {
    margin-bottom: 15px;
    padding: 10px;
    background-color: #f0f8ff;
    border-left: 4px solid #007bff;
}

.oeg-job-info-box p {
    margin: 5px 0;
}

/* Styles for modal close button */
.oeg-modal-close-button {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
}

/* Styles for loading indicators */
.oeg-loading-text {
    color: #666;
    font-style: italic;
}

/* Styles for error messages */
.oeg-error-message {
    color: red;
}

/* Styles for warning messages */
.oeg-warning-message {
    color: orange;
}

/* Additional button state classes */
.oeg-apply-button-enabled {
    background-color: #204f70;
    cursor: pointer;
}

.oeg-apply-button-enabled:hover {
    background-color: #183d5a;
}

.oeg-apply-button-disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
}

.oeg-apply-button-error {
    background-color: #dc3545;
    color: white;
    cursor: pointer;
}

/* Styles for job description content */
.oeg-job-description {
    margin-top: 10px;
    line-height: 1.6;
    color: #333;
}

/* Oracle Skills Selector Component Styles */
.oeg-skills-container {
    margin: 15px 0 0 0;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    background-color: #fdfdfd;
    position: relative;
}

.oeg-skills-container label {
    display: block;
    margin-bottom: 10px;
    color: #333;
    font-size: 1.1em;
}

.oeg-skills-search {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

.oeg-skills-search:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.oeg-selected-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
    min-height: 40px;
    padding: 8px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #f8f9fa;
    align-items: flex-start;
    align-content: flex-start;
}

.oeg-no-skills {
    color: #666;
    font-style: italic;
    font-size: 0.9em;
    align-self: center;
}

.oeg-skill-tag {
    background-color: #204f70;
    color: white;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 0.85em;
    display: flex;
    align-items: center;
    gap: 6px;
    max-width: 200px;
    transition: background-color 0.2s ease;
}

.oeg-skill-tag:hover {
    background-color: #183d5a;
}

.oeg-skill-tag span:first-child {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.oeg-skill-remove {
    cursor: pointer;
    font-weight: bold;
    font-size: 1.1em;
    padding: 0 2px;
    border-radius: 1px;
    transition: background-color 0.2s ease;
}

.oeg-skill-remove:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.oeg-skills-dropdown {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 99999;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.oeg-skill-option {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s ease;
}

.oeg-skill-option:last-child {
    border-bottom: none;
}

.oeg-skill-option:hover {
    background-color: #f8f9fa;
}

.oeg-skill-option.selected {
    background-color: #e3f2fd;
    color: #1976d2;
    cursor: default;
}

.oeg-skill-option.selected:hover {
    background-color: #e3f2fd;
}

.oeg-selected-indicator {
    font-weight: bold;
    color: #28a745;
}

.oeg-no-results {
    color: #666;
    font-style: italic;
    cursor: default;
}

.oeg-no-results:hover {
    background-color: white;
}

/* Button container for resume results page */
.oeg-button-container {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-top: 0px;
    padding-top: 15px;
}

.oeg-button-secondary {
    background-color: #315C2B !important;
    color: white;
    padding: 10px 20px;
    height: 39px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease;
    flex: 0 0 auto;
}

.oeg-button-secondary:hover {
    background-color: #254622 !important;
}

.oeg-button-primary {
    background-color: #204f70 !important;
    color: white;
    padding: 10px 20px;
    height: 39px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease;
    flex: 0 0 auto;
}

.oeg-button-primary:hover:not(:disabled) {
    background-color: #183d5a;
}

.oeg-button-primary:disabled {
    background-color: #cccccc !important;
    color: #666666 !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

/* Enhanced input styling for results page */
#city-input-container label,
#linkedin-input-container label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-weight: normal;
}

#city-input,
#linkedin-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 15px;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

#city-input:focus,
#linkedin-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

#city-input-container,
#linkedin-input-container {
    margin-bottom: 0;
    padding: 10px;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    background-color: #fdfdfd;
}

/* Styles for previous resume container */
.oeg-previous-resume-container {
    margin-bottom: 0px;
}

.oeg-previous-resume-container h5 {
    color: #333;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 14px;
}

.oeg-resume-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px;
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 15px;
}

.oeg-resume-name-display {
    flex-grow: 1;
    padding: 8px;
    font-size: 0.9em;
    color: #333;
    font-weight: 500;
}

.oeg-view-resume-button {
    background-color: #6c757d;
    color: white;
    padding: 10px 12px;
    height: 38px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85em;
    transition: background-color 0.3s ease;
}

.oeg-view-resume-button:hover {
    background-color: #5a6268;
}

.oeg-question-text {
    color: #333;
    font-size: 14px;
    margin-bottom: 15px;
    font-weight: 500;
}

#oeg-popup-pages-container .oeg-use-previous-button {
    background-color: #204f70;
    color: white;
    padding: 10px 20px;
    height: 38px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease;
    margin-bottom: 35px !important;
    margin-top: 5px;
    margin-left: 5px;
    margin-right: 5px;
}

#oeg-popup-pages-container .oeg-use-previous-button:hover {
    background-color: #183d5a;
}

/* Unified button row for previous resume and file upload */
.oeg-unified-button-row {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.oeg-unified-button-row .oeg-use-previous-button {
    margin-bottom: 35px;
    flex-shrink: 0;
    position: relative;
}

.oeg-unified-button-row .oeg-use-previous-button::after {
    content: '';
    position: absolute;
    top: 10%;
    right: -8px;
    width: 1px;
    height: 80%;
    background-color: #ddd;
}

.oeg-unified-button-row .oeg-file-upload-container {
    flex: 1;
    min-width: 300px;
}

/* Reusable file upload container */
.oeg-file-upload-container {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* File controls row - keeps controls horizontal */
.oeg-file-controls-row {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: space-between;
}

/* Group file selection controls on the left */
.oeg-file-upload-container .oeg-file-controls-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Override for new candidate container - keep horizontal layout */
#oeg-file-upload-container-new.oeg-file-upload-container {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.oeg-file-upload-container input[type="file"] {
    display: none; /* Hide the default file input */
}

.oeg-file-upload-container .choose-file-button {
    background-color: #315C2B;
    color: white;
    padding: 8px 15px;
    height: 38px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9em;
    transition: background-color 0.3s ease;
}

.oeg-file-upload-container .choose-file-button:hover {
    background-color: #254622;
}

.oeg-file-upload-container .file-name-display {
    flex-grow: 1;
    max-width: 200px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #f0f0f0;
    font-size: 0.9em;
    color: #555;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.oeg-file-upload-container .upload-resume-button {
    background-color: #204f70 !important;
    color: white;
    padding: 8px 15px;
    height: 38px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9em;
    transition: background-color 0.3s ease;
}

.oeg-file-upload-container .upload-resume-button:hover {
    background-color: #183d5a !important;
}

/* Form fields container */
#oeg-form-fields-container {
    overflow: visible;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    background-color: #fdfdfd;
    padding: 15px;
    margin-bottom: 0;
}

/* Remove individual container styling within unified form */
#oeg-form-fields-container .oeg-skills-container {
    border: none;
    background-color: transparent;
    padding: 0;
    margin: 15px 0 0 0;
}

#oeg-form-fields-container #city-input-container,
#oeg-form-fields-container #linkedin-input-container {
    margin-bottom: 0;
    border: none;
    background-color: transparent;
    padding: 0;
}

#oeg-form-fields-container #city-input-container:last-child,
#oeg-form-fields-container #linkedin-input-container:last-child {
    margin-bottom: 0;
}

/* Form row layout */
.oeg-form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.oeg-form-row:last-child {
    margin-bottom: 0;
}

/* Field containers - borderless styling */
.oeg-field-container {
    flex: 1;
    min-width: 0;
}

.oeg-field-container label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-weight: normal;
}

/* Required field asterisk styling */
.required {
    color: #ff0000;
    font-weight: bold;
}

/* LinkedIn container spans full width when visible */
#linkedin-input-container.oeg-field-container {
    flex: none;
    width: 100%;
    margin-bottom: 15px;
}

#first-name-input,
#last-name-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 0;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

#first-name-input:focus,
#last-name-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* Phone number fields layout */
.oeg-phone-fields {
    display: flex;
    gap: 10px;
}

#country-code-input,
#phone-number-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

#country-code-input {
    flex: 0 0 120px;
    min-width: 120px;
}

#phone-number-input {
    flex: 1;
    min-width: 200px;
}

#country-code-input:focus,
#phone-number-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* Responsive adjustments for phone fields and form rows */
@media (max-width: 600px) {
    .oeg-form-row {
        flex-direction: column;
        gap: 10px;
    }
    
    .oeg-phone-fields {
        flex-direction: column;
        gap: 5px;
    }
    
    #country-code-input {
        flex: none;
        min-width: auto;
    }
    
    #phone-number-input {
        flex: none;
        min-width: auto;
    }
}

/* Tooltip for file selection hint */
.oeg-tooltip {
    position: absolute;
    background-color: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-5px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.oeg-tooltip.show {
    opacity: 1;
    transform: translateY(0);
}

.oeg-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border: 5px solid transparent;
    border-top-color: #333;
}

/* Responsive adjustments for skills selector */
@media (max-width: 600px) {
    .oeg-skills-container {
        padding: 10px;
    }
    
    .oeg-skill-tag {
        font-size: 0.8em;
        padding: 4px 8px;
        max-width: 150px;
    }
    
    .oeg-skills-dropdown {
        left: 0;
        right: 0;
    }
    
    .oeg-button-container {
        flex-direction: column;
        gap: 10px;
    }
    
    .oeg-button-secondary,
    .oeg-button-primary {
        width: 100%;
    }
    
    .oeg-resume-info-row {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .oeg-view-resume-button {
        align-self: flex-end;
    }
    
    .oeg-unified-button-row {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .oeg-unified-button-row .oeg-file-upload-container {
        min-width: auto;
    }
    
    .oeg-file-upload-container {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .oeg-file-upload-container .file-name-display {
        min-width: 200px;
    }
}

/* Resume Formatter link styling */
.oeg-resume-formatter-link {
    color: #204f70;
    text-decoration: none;
    border-bottom: 1px dotted #204f70;
}

.oeg-resume-formatter-link:hover {
    color: #183d5a;
    border-bottom-color: #183d5a;
}

/* Info message styling - minimal and centered */
.oeg-info-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    height: 20px;
    margin-top: 5px;
    font-size: 0.75em;
    color: #666;
}

.oeg-info-icon {
    font-size: 0.9em;
    flex-shrink: 0;
}

.oeg-info-text {
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
