/* Custom CSS for PointsUp MVC Framework */

/* Toast Styles */
.toast-container {
    z-index: 9999;
}

.toast {
    min-width: 300px;
    max-width: 400px;
}

.toast-header {
    font-weight: 600;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.toast-header .toast-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 5px;
    flex-shrink: 0;
}

.toast-header .toast-icon i {
    font-size: 1.1em;
}

.toast-body {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
}

/* Main Layout Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

.text-1 {
    color: #004c87;
}

.login-switch-link {
    color: #004aad;
}

/* Card Header Styles */
.card-header {
    background-color: #fff !important;
}

.title-uppercase {
    text-transform: uppercase !important;
}

.btn-register {
    background-color: #004AAD !important;
    color: #fff !important;
}

#candidate-register-form .btn-register {
    background-color: #FDB800 !important;
}

/* Container Fluid with Max Width */
.container {
    max-width: 1300px;
}
.container-fluid {
    max-width: 1300px;
    margin: 0 auto;
}

/* CAPTCHA Layout */
.captcha-container {
    margin-bottom: 0 !important;
}

.captcha-image {
    margin-bottom: 0 !important;
}

/* Form Validation Error Positioning */
.invalid-feedback {
    display: block !important;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #dc3545;
}

/* User Avatar Styles */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #004aad;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
    overflow: hidden;
}
.user-avatar .user-avatar-img,
.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.is-invalid ~ .invalid-feedback {
    display: block !important;
}

/* Ensure error messages appear directly after their input */
.form-control + .invalid-feedback {
    display: block !important;
    margin-top: 0.25rem;
}

/* Reduce gap between CAPTCHA columns */
.row .col-md-3:first-child {
    padding-right: 5px;
}

.row .col-md-9:last-child {
    padding-left: 5px;
}

/* Navigation Styles */
.navbar-brand {
    font-weight: 600;
}

.navbar-nav .nav-link {
    font-weight: 500;
}

/* Footer Styles */
footer {
    margin-top: auto;
}

/* Utility Classes */
.text-muted {
    color: #6c757d !important;
}
.form-select {
    font-size: 14px;
}
.form-label {
    font-size: 14px;
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
}

.form-component .form-control,
.form-component .form-select {
    border-radius: 0.375rem;
    border: 1px solid #ced4da;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-component .form-control:focus,
.form-component .form-select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.form-component .is-invalid {
    border-color: #dc3545;
}

.form-component .is-valid {
    border-color: #198754;
}

/* Toast Container Styles */
.toast-container {
    z-index: 1055;
}

.toast {
    min-width: 300px;
    max-width: 400px;
}


.toast-body {
    padding: 0.75rem;
}

/* Modal Styles */
.modal-header {
    border-bottom: 1px solid #dee2e6;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
}

/* Component Demo Styles */
.component-demo {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 0.375rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.code-example {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 0.375rem;
    padding: 1rem;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    line-height: 1.4;
    overflow-x: auto;
}

/* Button Styles */
.btn-group .btn {
    margin-right: 0.25rem;
}

.btn-group .btn:last-child {
    margin-right: 0;
}

/* Card Styles */
.card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border: 1px solid rgba(0, 0, 0, 0.125);
    transition: box-shadow 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Jumbotron Styles */
.jumbotron {
    background: linear-gradient(135deg, #004aad 0%, #005a9e 100%);
    border-radius: 0.5rem;
    padding: 3rem 2rem;
    margin-bottom: 2rem;
}

/* List Group Styles */
.list-group-item {
    border: 1px solid rgba(0, 0, 0, 0.125);
    transition: background-color 0.15s ease-in-out;
}

.list-group-item:hover {
    background-color: #f8f9fa;
}

/* Icon Styles */
.fa-3x {
    font-size: 3em;
}

.fa-2x {
    font-size: 2em;
}


/* Animation Styles */
.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

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

/* Loading Styles */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

/* Utility Classes */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.text-truncate-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Navigation Styles */
.navbar-nav .nav-link {
    color: white !important;
    font-weight: 500;
}

.navbar-nav .nav-link:hover {
    color: #f8f9fa !important;
    text-decoration: none;
}

.navbar-nav .nav-link:focus {
    color: white !important;
}

/* Language Switcher Styles */
.language-switcher .btn-outline-secondary {
    background-color: white !important;
    border-color: white !important;
    color: #004aad !important;
    font-weight: 500;
}

.language-switcher .btn-outline-secondary:hover {
    background-color: #f8f9fa !important;
    border-color: #f8f9fa !important;
    color: #004aad !important;
}

.language-switcher .dropdown-menu {
    background-color: white;
    border: 1px solid #dee2e6;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.language-switcher .dropdown-item {
    color: #333;
    padding: 0.5rem 1rem;
}

.language-switcher .dropdown-item:hover {
    background-color: #f8f9fa;
    color: #004aad;
}

.language-switcher .dropdown-item.active {
    background-color: #004aad;
    color: white;
}

/* Navigation Button Styles */
.btn-nav-white,
.btn-nav-outline {
    height: 40px;
    line-height: 1;
    padding: 8px 16px;
    font-weight: 400;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 14px;
    border-radius: 6px;
    min-width: 100px;
    white-space: nowrap;
}

.btn-nav-white {
    background-color: white;
    color: #333;
    border: 2px solid white;
}

.btn-nav-white:hover {
    background-color: #f8f9fa;
    color: #333;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-nav-white:focus {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5);
    outline: none;
}

.btn-nav-white:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-nav-outline {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-nav-outline:hover {
    background-color: white;
    color: #333;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(255, 255, 255, 0.3);
}

.btn-nav-outline:focus {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5);
    outline: none;
}

.btn-nav-outline:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(255, 255, 255, 0.3);
}

/* Language Switcher Button Sync */
.language-switcher .btn-outline-secondary {
    height: 40px !important;
    line-height: 1 !important;
    padding: 8px 16px !important;
    font-weight: 400 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    font-size: 14px !important;
    border-radius: 6px !important;
    min-width: 100px !important;
    white-space: nowrap !important;
    border: 2px solid white !important;
}


.language-switcher .btn-outline-secondary:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 8px rgba(255, 255, 255, 0.3) !important;
}

/* Mobile language switcher - hidden by default on desktop */
@media (min-width: 992px) {
    .mobile-language-switcher {
        display: none !important;
    }
}

.language-switcher .btn-outline-secondary:focus {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5) !important;
    outline: none !important;
}

.language-switcher .btn-outline-secondary:active {
    transform: translateY(0) !important;
    box-shadow: 0 2px 4px rgba(255, 255, 255, 0.3) !important;
}

/* Loading Screen Styles */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #004aad;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Logo Styles */
.logo-img {
    max-height: 40px;
    width: auto;
    transition: all 0.3s ease;
}

.navbar-brand .logo-img {
    filter: brightness(0) invert(1); /* Make logo white for dark navbar */
}

.admin-sidebar .logo-img {
    filter: brightness(0) invert(1); /* Make logo white for dark sidebar */
}

/* User Avatar Styles */
.user-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: #fdd800;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.user-avatar:hover {
    background: #fdd800;
    transform: scale(1.05);
    transition: all 0.3s ease;
}

/* Navigation Dropdown Styles */
.navbar-nav .dropdown-menu {
    background-color: white;
    border: 1px solid #dee2e6;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border-radius: 0.375rem;
    min-width: 200px;
}

.navbar-nav .dropdown-item {
    color: #333;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.navbar-nav .dropdown-item:hover {
    background-color: #f8f9fa;
    color: #fdd800;
}

.navbar-nav .dropdown-item i {
    width: 16px;
    text-align: center;
}

.navbar-nav .dropdown-header {
    color: #000000;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.5rem 1rem 0.25rem;
}

.inner-banner-slider-link {
    display: block;
}

.inner-banner-slider-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slick-slider .slick-dots li button {
    background-color: #000;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    padding: 0;
    margin: 0;
    border: none;
    outline: none;
    cursor: pointer;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.slick-slider  .slick-dots li,
.slick-slider  .slick-dots li button:before {
    width: 14px;
    height: 14px;
}

.slick-slider  .slick-dots li {
    margin: 7px;
}

.slick-dots li button:hover {
    opacity: 1;
}

.slick-dots li button:focus {
    opacity: 1;
}

.slick-slider .slick-dots {
    bottom: 0;
}

/* Responsive Styles - Mobile/Tablet (max-width: 991px) */
@media (max-width: 991px) {
    .jumbotron {
        padding: 2rem 1rem;
    }
    
    .jumbotron h1 {
        font-size: 2rem;
    }
    
    .component-demo {
        padding: 1rem;
    }
    
    .code-example {
        font-size: 0.75rem;
    }
    
    /* Navigation buttons spacing on mobile */
    .navbar-nav .btn-nav-white {
        margin-bottom: 10px;
        margin-right: 0;
    }
    
    .navbar-nav .btn-nav-outline {
        margin-bottom: 10px;
        margin-right: 0;
    }
    
    .navbar-nav .language-switcher {
        margin-bottom: 10px;
        margin-right: 0;
    }
    
    /* Stack navigation buttons vertically on mobile */
    .navbar-nav.ms-auto {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }
    
    .navbar-nav.ms-auto .btn {
        width: 100%;
        max-width: 200px;
    }
    
    /* Hide desktop language switcher on mobile/tablet */
    .navbar-nav .language-switcher {
        display: none !important;
    }
    
    /* Mobile language switcher next to toggle button */
    .navbar-toggler {
        position: relative;
    }
    
    .mobile-language-switcher {
        position: absolute !important;
        right: 90px !important;
        top: 15px !important;
        z-index: 1000 !important;
        display: block !important;
    }
    
    .mobile-language-switcher .btn-outline-secondary {
        height: 35px !important;
        padding: 5px 10px !important;
        font-size: 12px !important;
        min-width: 80px !important;
        background-color: white !important;
        color: #004aad !important;
        border: 1px solid white !important;
    }
    
    .mobile-language-switcher .btn-outline-secondary:hover {
        background-color: #f8f9fa !important;
        color: #004aad !important;
    }
}

/* Workplace Images Gallery */
.workplace-images-section {
    margin-top: 1rem;
}

.workplace-images-gallery {
    margin-top: 1rem;
}

.workplace-image-item {
    position: relative;
}

.workplace-image-item img {
    width: 100%;
    height: auto;
    max-height: 200px;
    object-fit: cover;
    transition: transform 0.2s ease;
}

.workplace-image-item:hover img {
    transform: scale(1.02);
}

.workplace-image-actions {
    position: absolute;
    top: 5px;
    right: 5px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.workplace-image-item:hover .workplace-image-actions {
    opacity: 1;
}

.workplace-image-view-btn,
.workplace-image-delete-btn {
    opacity: 1;
}

.workplace-image-actions:hover {
    opacity: 1 !important;
}

.workplace-image-thumb {
    cursor: pointer;
}

.workplace-images-upload-label {
    cursor: pointer;
    margin: 0;
}

.workplace-images-input {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .workplace-images-gallery .col-md-3 {
        flex: 0 0 50%;
        max-width: 50%;
    }
    
    .workplace-image-delete-btn {
        opacity: 1; /* Always show on mobile */
    }
}

/* Profile Loading Overlay */
/* Profile Loading Overlay - White Background */
.profile-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.profile-loading-content {
    text-align: center;
    color: #333;
}

.profile-loading-content .spinner-border {
    border-width: 0.3rem;
}

.profile-loading-content h5 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
}

.profile-loading-content p {
    font-size: 0.95rem;
    color: #666;
}

/* Register Loading Overlay - White Background */
.register-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.register-loading-content {
    text-align: center;
    color: #333;
}

.register-loading-content .spinner-border {
    border-width: 0.3rem;
}

.register-loading-content h5 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
    margin-top: 1rem;
}
