/* =========================================
   1. GLOBAL VARIABLES & BACKGROUND
   ========================================= */
:root {
  --primary-color: #077c8c;
  --primary-dark: #056674;
  --secondary-color: #dfedf1;
  --text-dark: #2c3e50;
  --text-light: #7f8c8d;
  --sidebar-width: 280px;
  --border-radius: 12px;

  /* 🔥 RESTORED: Aapka Gradient Background */
  --bg-gradient: linear-gradient(to bottom, rgba(223, 237, 241, 0.5) 0%, rgba(255, 255, 255, 0) 100%);
}

* {
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
}

body {
  background: var(--bg-gradient);
  background-attachment: fixed;
  min-height: 100vh;
  color: var(--text-dark);
}

/* =========================================
   2. LAYOUT (CONTAINER & SPACING)
   ========================================= */
.main-container {
  max-width: 1300px;
  margin: 85px auto 40px auto;
  /* Desktop Top Gap */
  padding: 0 20px;
}

@media (max-width: 991px) {
  .main-container {
    padding: 0 15px;
    margin-top: 60px;
    /* Mobile Top Gap */
  }
}






/* =========================================
   SIDEBAR (MATCHING JOB CARD STYLE)
   ========================================= */

.sidebar {
  background: #fff;
  padding: 24px;
  /* Job Card jaisa same radius */
  border-radius: 12px; 
  /* Job Card jaisa same light border */
  border: 1px solid #f0f0f0; 
  /* Job Card jaisa same soft shadow */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02); 
  position: -webkit-sticky;
  position: sticky;
  top: 90px;
  z-index: 10;
  height: fit-content;
}

/* Hover effect bhi Job Card jaisa */
.sidebar:hover {
    box-shadow: 0 12px 30px rgba(7, 124, 140, 0.10); /* Thoda highlight */
    border-color: transparent;
    transition: all 0.3s ease;
}

/* Baaki CSS Same rahegi (Header, Inputs etc.) */
.filter-header-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #f5f5f5;
  padding-bottom: 15px;
}

.filter-main-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-dark);
  margin: 0;
}

.clear-all-btn {
  color: var(--primary-color);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.search-input-styled {
  background: #f8f9fa;
  border: 1px solid #e9ecef; /* Halka border input ke liye */
  border-radius: 8px;
  padding: 10px 40px 10px 15px;
  font-size: 0.9rem;
  width: 100%;
  color: #333;
}
.search-input-styled:focus {
  background: #fff;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(7, 124, 140, 0.1);
  outline: none;
}

.search-icon-pos {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #adb5bd;
  pointer-events: none;
}

/* Filter Item Styling */
.filter-section {
  margin-bottom: 20px;
}

.group-title {
  font-weight: 600;
  font-size: 0.95rem;
  color: #2c3e50;
  cursor: pointer;
  padding: 5px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.transition-icon {
  transition: transform 0.3s ease;
  font-size: 0.75rem;
  color: #ccc;
}
.group-title[aria-expanded="true"] .transition-icon {
  transform: rotate(180deg);
  color: var(--primary-color);
}

/* Checkboxes */
.custom-checkbox {
  margin-bottom: 8px;
  display: flex;
  align-items: center;
}
.custom-checkbox .form-check-input {
  width: 1.1em;
  height: 1.1em;
  margin-top: 0;
  margin-right: 10px;
  cursor: pointer;
  border: 1.5px solid #d1d5db;
}
.custom-checkbox .form-check-input:checked {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}
.custom-checkbox .form-check-label {
    color: #555;
    font-size: 0.9rem;
    cursor: pointer;
}

/* Slider */
.salary-label { font-size: 0.9rem; font-weight: 600; color: #333; }
.custom-range::-webkit-slider-thumb { background: var(--primary-color); }













/* =========================================
   4. JOB CARD STYLING
   ========================================= */
.job-card {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #f0f0f0;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  height: 100%;
  position: relative;
}

.job-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(7, 124, 140, 0.15);
  border-color: transparent;
}

.job-header {
  display: flex;
  gap: 15px;
  margin-bottom: 15px;
}

.company-logo {
  width: 50px;
  height: 50px;
  border-radius: 10px;
  padding: 4px;
  border: 1px solid #eee;
  background: #fff;
  object-fit: contain;
  flex-shrink: 0;
}

.job-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 2px;
  line-height: 1.3;
  color: var(--text-dark);
}


.company-name {
  font-size: 0.85rem;
  color: #666;
  font-weight: 600;
  white-space: nowrap;       
  overflow: hidden;          
  text-overflow: ellipsis;   
  max-width:80%;           
  display: block;
}

.job-details {
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.detail-item {
  font-size: 0.85rem;
  color: #555;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tags-container {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.job-tag {
  padding: 5px 12px;
  font-size: 0.75rem;
  border-radius: 6px;
  background: #f1f3f5;
  border: 1px solid #e9ecef;
  color: #555;
  font-weight: 600;
}

/* Buttons inside Card */
.view-details-btn {
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  font-weight: 600;
  border-radius: 8px;
  background: transparent;
  font-size: 0.9rem;
  transition: 0.3s;
}

.view-details-btn:hover {
  background: #e0f7fa;
  /* Text color ko force karein ki wo Teal hi rahe */
  color: var(--primary-color) !important; 
}

.quick-apply-btn {
  background-color: var(--primary-color);
  color: white;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  font-size: 0.9rem;
  transition: 0.3s;
}

.quick-apply-btn:hover {
  /* Hover pr background thoda dark karein taaki click feel aaye */
  background-color: var(--primary-dark) !important; 
  /* Text color ko force karein ki wo White hi rahe */
  color: #ffffff !important; 
}
/* =========================================
   5. SAVE BUTTON
   ========================================= */
.save-btn {
  background: white;
  border: 1px solid #d1d5db;
  border-radius: 50%;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  color: #077c8c;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
  position: relative;
}

.save-btn:hover {
  background-color: #e0f7fa;
  color: #056674;
  border-color: #077c8c;
  transform: scale(1.1);
}

.save-btn.saved {
  background-color: var(--primary-color) !important;
  color: #ffffff !important;
  border-color: var(--primary-color) !important;
  box-shadow: 0 4px 10px rgba(7, 124, 140, 0.4);
}

/* Tooltip for Save Button */
.save-btn::after {
  content: "Save Job";
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #333;
  color: #fff;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: 0.2s;
  pointer-events: none;
}

.save-btn:hover::after {
  opacity: 1;
  visibility: visible;
  bottom: 115%;
}

.save-btn.saved:hover::after {
  content: "Saved";
  background-color: var(--primary-color);
}





/* =========================================
   6. MOBILE TOP STICKY HEADER (Search + Filter)
   ========================================= */
.filter-chips-container {
  display: none;
}

@media (max-width: 991px) {
  .filter-chips-container {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    margin-bottom: 20px;
    position: sticky;
    top: 0; /* Sticky to very top */
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid #f0f0f0;
    backdrop-filter: blur(8px);
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  }

  /* Filter Icon Section */
  .filter-icon-fixed {
    padding-right: 15px;
    color: var(--primary-color, #077c8c);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #eee;
  }

  /* Search Bar Wrapper */
  .mobile-search-wrapper {
    flex-grow: 1; /* Takes remaining space */
    position: relative;
    margin-left: 15px;
    display: flex;
    align-items: center;
  }

  /* Search Icon (Right Side) */
  .mobile-search-wrapper i {
    position: absolute;
    right: 15px;
    font-size: 0.9rem;
    color: #aaa;
    pointer-events: none;
  }

  /* The Input Field (Padding Adjusted for Right Icon) */
  .mobile-search-input {
    width: 100%;
    border: none;
    background-color: #f3f4f6;
    padding: 10px 40px 10px 15px; /* Right padding 40px for icon */
    border-radius: 50px;
    font-size: 0.95rem;
    color: #333;
    transition: all 0.3s ease;
    box-shadow: none !important;
  }

  .mobile-search-input:focus {
    background-color: #fff;
    box-shadow: 0 0 0 1px var(--primary-color, #077c8c) !important;
  }

  .mobile-search-input::placeholder {
    color: #999;
    font-size: 0.9rem;
  }
}

/* =========================================
   7. MODAL STYLES
   ========================================= */
@media (min-width: 992px) {
  .job-modal-dialog {
    max-width: 500px !important;
    margin: 1.75rem auto;
  }
}

.modal-content {
  border-radius: 16px;
  border: none;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  background: #fff;
  overflow: hidden;
}

.modal-logo-wrapper {
  width: 70px;
  height: 70px;
  border-radius: 14px;
  border: 1px solid #f0f0f0;
  padding: 8px;
  background: #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem auto;
}

#mLogo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.modal-pill {
  font-size: 0.85rem;
  background: #f8f9fa;
  color: #555;
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid #eee;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.section-heading {
  font-size: 1.1rem !important;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 10px;
  text-transform: uppercase;
}

.apply-btn-lg {
  width: 100%;
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 14px;
  border-radius: 12px;
  font-weight: 600;
  transition: 0.3s;
}

.apply-btn-lg:hover {
  background-color: var(--primary-dark);
  transform: translateY(-2px);
}

/* =========================================
   8. MOBILE FILTER OFFCANVAS & SLIDER
   ========================================= */
/* Offcanvas Height Fix */
#mobileFilterCanvas {
  height: 85vh !important;
  border-radius: 20px 20px 0 0;
}

/* Hidden Checkbox */
.mobile-filter-input {
  display: none;
}

/* Unselected State (Gray Chip) */
.mobile-filter-chip {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid #e0e0e0;
  background-color: #f8f9fa;
  color: #555;
  border-radius: 50px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  font-weight: 500;
  margin-bottom: 8px;
}

/* Selected State (Teal Chip) */
.mobile-filter-input:checked+.mobile-filter-chip {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  box-shadow: 0 2px 5px rgba(7, 124, 140, 0.3);
}

/* Salary Slider Color Fix */
.custom-range::-webkit-slider-thumb {
  background: var(--primary-color);
}

/* =========================================
   9. FINAL ALIGNMENT FIX (Desktop)
   ========================================= */
@media (min-width: 992px) {
  /* Force Align Top */
  .sidebar {
    margin-top: 0 !important;
  }
  
  .job-content {
    margin-top: 0 !important;
    padding-top: 0 !important;
    
  }

  .row {
    align-items: start !important;
  }
}















/* =========================================
   9. FINAL ALIGNMENT FIX (Desktop)
   ========================================= */
@media (min-width: 992px) {
  /* Force Align Top */
  .sidebar {
    margin-top: 0 !important;
  }

  .job-content {
    margin-top: 0 !important;
    padding-top: 0 !important;
  }

  .row {
    align-items: start !important;
  }
}

/* =========================================
   10. ADDITIONAL STYLES FOR QUICK APPLY MODAL
   ========================================= */

.job-yatra-modal {
  border-radius: 12px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.text-primary-custom {
  color: var(--primary-color);
}

.resume-list-wrapper {
  max-height: 260px;
  overflow-y: auto;
  padding-right: 5px;
  background: #fdfdfd;
  border: 1px solid #f1f1f1;
  border-radius: 8px;
  padding: 10px;
}

.resume-list-wrapper::-webkit-scrollbar {
  width: 5px;
}

.resume-list-wrapper::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.resume-list-wrapper::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

.resume-card {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 8px;
  cursor: pointer;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.2s ease;
}

.resume-card:hover {
  background-color: #f8f9fa;
  border-color: #b0bec5;
}

.resume-card.selected {
  border: 2px solid var(--primary-color);
  background-color: #f0fbfc;
}

.custom-show-btn {
  color: #077c8c !important;
  font-size: 0.9rem;
  transition: 0.3s;
}

.custom-show-btn:hover {
  color: #056674 !important;
  text-decoration: none !important;
}

.pdf-icon-box {
  width: 32px;
  height: 40px;
  background-color: #d32f2f;
  color: white;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 8px;
  flex-shrink: 0;
}

.custom-radio-circle {
  width: 18px;
  height: 18px;
  border: 2px solid #adb5bd;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
}

.custom-radio-circle::after {
  content: '';
  width: 10px;
  height: 10px;
  border-radius: 50%;
  transition: all 0.2s;
}

.resume-card.selected .custom-radio-circle {
  border-color: var(--primary-color);
}

.resume-card.selected .custom-radio-circle::after {
  background: var(--primary-color);
}

.btn-primary-custom {
  background-color: var(--primary-color);
  border: none;
  color: white;
}

.btn-primary-custom:hover {
  background-color: var(--primary-dark);
  color: white;
}

.btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
  font-size: 0.85rem;
}

.btn-outline-primary:hover {
  background-color: #e0f7fa;
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.action-btn {
  color: #6c757d;
  background: none;
  border: none;
  padding: 5px;
}

.action-btn:hover {
  color: #343a40;
  background-color: #f1f1f1;
  border-radius: 50%;
}

@media (max-width: 576px) {
  .modal-body,
  .modal-footer {
    padding: 1rem !important;
  }

  .text-nowrap {
    white-space: normal !important;
  }
}

/* =========================================
   1. DESKTOP & GENERAL LAYOUT view details
   ========================================= */
.job-section-item {
  display: flex;
  margin-bottom: 1.5rem;
}

.section-icon-box {
  flex-shrink: 0;
  width: 45px;
  height: 45px;
  background-color: #e6f2f4;
  color: #077c8c;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 15px;
  font-size: 1.1rem;
}

.section-content h6 {
  font-weight: 700;
  margin-bottom: 0.3rem;
  color: #333;
}

.section-content p,
.section-content ul,
.section-content li {
  color: #6c757d;
  font-size: 1rem;
  margin-bottom: 0;
  line-height: 1.5;
}

/* =========================================
   2. SCROLLBAR STYLING (PC & Mobile)
   ========================================= */
#jobDetailModal .modal-body::-webkit-scrollbar {
  width: 6px;
}

#jobDetailModal .modal-body::-webkit-scrollbar-track {
  background: transparent;
}

#jobDetailModal .modal-body::-webkit-scrollbar-thumb {
  background-color: #d1d1d1;
  border-radius: 10px;
}

#jobDetailModal .modal-body {
  scrollbar-width: thin;
  scrollbar-color: #d1d1d1 transparent;
}

/* =========================================
   3. SKILLS TEXT WRAP FIX
   ========================================= */
#mSkills, #mSkills > * {
  white-space: normal !important;
  word-wrap: break-word !important;
  overflow-wrap: break-word !important;
  max-width: 100%;
}

#mSkills {
  overflow-x: hidden !important;
}

/* =========================================
   4. MOBILE OPTIMIZATION (Fix Scroll & Height)
   ========================================= */
@media (max-width: 576px) {

  /* 1. Dialog Positioning */
  .job-modal-dialog {
    margin: 1rem auto;
    max-width: 92%;
    height: calc(100% - 2rem);
    display: flex;
    align-items: center;
    min-height: auto !important;
  }

  /* 2. Modal Content (The Card) */
  .modal-content {
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    border-radius: 15px !important;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    overflow: hidden;
  }

  /* 3. Modal Header & Footer (Fixed) */
  .modal-header,
  .modal-footer {
    flex-shrink: 0;
  }

  /* 4. Modal Body (Scrollable Area) */
  .modal-body {
    flex-grow: 1;
    overflow-y: auto !important;
    padding-bottom: 20px;
  }

  /* --- Element Resizing --- */
  .modal-logo-wrapper {
    width: 55px !important;
    height: 55px !important;
    margin-bottom: 0.5rem !important;
  }

  #mTitle {
    font-size: 1.15rem;
  }

  #mCompany {
    font-size: 0.9rem;
    margin-bottom: 0.5rem !important;
  }

  .section-icon-box {
    width: 32px;
    height: 32px;
    font-size: 1rem;
    margin-right: 12px;
  }

  .job-section-item {
    margin-bottom: 1rem;
  }

  .section-content h6 {
    font-size: 0.9rem;
  }
  .section-content p,
  .section-content li,
  .section-content ul {
    font-size: 0.85rem;
    line-height: 1.45;
  }
  /* Footer styling adjustment */
  .modal-footer {
    padding: 10px 15px 15px 15px !important;
    background-color: #fff;
    border-top: 1px solid #f0f0f0;
  }

  #confirmApplyBtn {
    font-size: 1rem;
    padding: 10px;
  }
}
/* =============================================
   FIX: Modal Gap / Scrollbar Issue
   ============================================= */
body.modal-open {
  padding-right: 0 !important;
  overflow-y: auto !important;
}