/**
 * Semolina Italian Restaurant - Executive Chef Application Page Styles
 * Bespoke luxury dark trattoria aesthetics matching Semolina brand
 */

/* ==========================================================================
   Popup Modal Overlay & Container
   ========================================================================== */
#job-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99990;
  background: rgba(10, 9, 8, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 15px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.4s ease;
  overflow-y: auto;
}

#job-modal-backdrop.is-active {
  opacity: 1;
  visibility: visible;
}

.job-modal-card {
  width: 100%;
  max-width: 780px;
  background: #141311;
  background: linear-gradient(165deg, #1b1915 0%, #11100e 100%);
  border: 1px solid rgba(205, 164, 94, 0.35);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.8), 0 0 40px rgba(205, 164, 94, 0.12);
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  margin: auto;
  transform: translateY(25px) scale(0.97);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 40px);
}

#job-modal-backdrop.is-active .job-modal-card {
  transform: translateY(0) scale(1);
}

/* Modal Header */
.job-modal-header {
  padding: 26px 32px 20px;
  border-bottom: 1px solid rgba(205, 164, 94, 0.18);
  position: relative;
  background: rgba(22, 20, 17, 0.85);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.job-modal-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(205, 164, 94, 0.12);
  border: 1px solid rgba(205, 164, 94, 0.3);
  color: #cda45e;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 5px 12px;
  border-radius: 30px;
  margin-bottom: 10px;
}

.job-modal-badge i {
  font-size: 13px;
}

.job-modal-title {
  font-family: var(--heading-font, "Playfair Display", serif);
  color: #ffffff;
  font-size: 26px;
  font-weight: 700;
  margin: 0 0 6px 0;
  line-height: 1.25;
}

.job-modal-title span {
  color: #cda45e;
}

.job-modal-subtitle {
  color: rgba(255, 255, 255, 0.65);
  font-size: 13.5px;
  margin: 0;
  line-height: 1.5;
}

.job-modal-close {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(205, 164, 94, 0.3);
  color: #cda45e;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s ease;
  font-size: 18px;
  flex-shrink: 0;
  margin-left: 15px;
}

.job-modal-close:hover {
  background: #cda45e;
  color: #0c0b09;
  transform: rotate(90deg);
}

/* Modal Body */
.job-modal-body {
  padding: 26px 32px 30px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(205, 164, 94, 0.4) transparent;
}

.job-modal-body::-webkit-scrollbar {
  width: 6px;
}

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

.job-modal-body::-webkit-scrollbar-thumb {
  background: rgba(205, 164, 94, 0.35);
  border-radius: 3px;
}

/* Section Dividers within Form */
.form-section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #cda45e;
  font-size: 13.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 22px 0 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(205, 164, 94, 0.15);
}

.form-section-title:first-of-type {
  margin-top: 0;
}

.form-section-title i {
  font-size: 16px;
}

/* Form Groups & Inputs */
.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 7px;
}

.form-label .req {
  color: #cda45e;
  margin-left: 3px;
  font-weight: bold;
}

.form-label-hint {
  display: block;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 3px;
  font-weight: 400;
}

.form-control-custom {
  width: 100%;
  background: rgba(20, 18, 15, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 11px 15px;
  color: #ffffff;
  font-size: 14px;
  font-family: inherit;
  transition: all 0.25s ease;
  outline: none;
}

.form-control-custom:focus {
  border-color: #cda45e;
  background: rgba(28, 25, 21, 0.95);
  box-shadow: 0 0 0 3px rgba(205, 164, 94, 0.18);
  color: #ffffff;
}

.form-control-custom::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

select.form-control-custom {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23cda45e' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}

select.form-control-custom option {
  background: #191714;
  color: #ffffff;
  padding: 10px;
}

textarea.form-control-custom {
  resize: vertical;
  min-height: 85px;
}

/* Radio & Checkbox Experience Chips */
.chip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 10px;
}

.chip-item {
  position: relative;
}

.chip-item input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip-label {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.chip-item input:checked + .chip-label {
  background: rgba(205, 164, 94, 0.16);
  border-color: #cda45e;
  color: #f7e6c4;
  box-shadow: 0 0 12px rgba(205, 164, 94, 0.15);
  font-weight: 600;
}

.chip-item:hover .chip-label {
  border-color: rgba(205, 164, 94, 0.5);
  color: #ffffff;
}

/* Expertise Multi-Select Checkboxes */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

@media (max-width: 768px) {
  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .skills-grid {
    grid-template-columns: 1fr;
  }
}

.skill-checkbox-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.skill-checkbox-card:has(input:checked) {
  background: rgba(205, 164, 94, 0.12);
  border-color: rgba(205, 164, 94, 0.5);
}

.skill-checkbox-card input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 1.5px solid rgba(205, 164, 94, 0.5);
  border-radius: 4px;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
  position: relative;
}

.skill-checkbox-card input[type="checkbox"]:checked {
  background: #cda45e;
  border-color: #cda45e;
}

.skill-checkbox-card input[type="checkbox"]:checked::after {
  content: "";
  width: 5px;
  height: 9px;
  border: solid #0c0b09;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  margin-top: -2px;
}

.skill-checkbox-card:hover {
  background: rgba(205, 164, 94, 0.06);
  border-color: rgba(205, 164, 94, 0.35);
}

.skill-checkbox-card span {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.82);
}

/* Drag and Drop CV File Upload Box */
.cv-upload-zone {
  border: 2px dashed rgba(205, 164, 94, 0.35);
  border-radius: 12px;
  padding: 24px 20px;
  text-align: center;
  background: rgba(205, 164, 94, 0.03);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
}

.cv-upload-zone:hover,
.cv-upload-zone.dragover {
  border-color: #cda45e;
  background: rgba(205, 164, 94, 0.09);
  box-shadow: 0 0 20px rgba(205, 164, 94, 0.12);
}

.cv-upload-icon {
  width: 52px;
  height: 52px;
  background: rgba(205, 164, 94, 0.12);
  color: #cda45e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 12px;
  transition: transform 0.25s ease;
}

.cv-upload-zone:hover .cv-upload-icon {
  transform: translateY(-3px) scale(1.05);
}

.cv-upload-title {
  color: #ffffff;
  font-size: 14.5px;
  font-weight: 600;
  margin-bottom: 4px;
}

.cv-upload-title span {
  color: #cda45e;
  text-decoration: underline;
}

.cv-upload-hint {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
  margin: 0;
}

.cv-file-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

/* File Selected Preview Badge */
.cv-selected-box {
  display: none;
  align-items: center;
  justify-content: space-between;
  background: rgba(40, 167, 69, 0.12);
  border: 1px solid rgba(40, 167, 69, 0.4);
  padding: 12px 16px;
  border-radius: 10px;
  margin-top: 10px;
}

.cv-selected-box.is-active {
  display: flex;
}

.cv-selected-info {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}

.cv-selected-info i {
  font-size: 24px;
  color: #34d399;
}

.cv-selected-name {
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
}

.cv-selected-size {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
}

.cv-remove-btn {
  background: transparent;
  border: none;
  color: #f87171;
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: 0.2s;
  display: flex;
  align-items: center;
}

.cv-remove-btn:hover {
  background: rgba(248, 113, 113, 0.15);
}

/* Terms / KVKK Checkbox */
.kvkk-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.5;
  cursor: pointer;
  margin: 18px 0;
  user-select: none;
}

.kvkk-label input[type="checkbox"] {
  margin-top: 2px;
  accent-color: #cda45e;
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* Modal Footer & Submit Button */
.job-modal-footer {
  padding-top: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-job-submit {
  width: 100%;
  background: #cda45e;
  color: #0c0b09;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 15px 30px;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 20px rgba(205, 164, 94, 0.3);
}

.btn-job-submit:hover {
  background: #deb86d;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(205, 164, 94, 0.45);
}

.btn-job-submit:active {
  transform: translateY(0);
}

.btn-job-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn-job-submit .spinner-border {
  width: 18px;
  height: 18px;
  border-width: 2px;
  display: none;
}

.btn-job-submit.is-loading .spinner-border {
  display: inline-block;
}

.btn-job-submit.is-loading .btn-text,
.btn-job-submit.is-loading i.bi-send {
  display: none;
}

/* Success Confirmation Screen (Başvuruyu Tamamla) */
#job-success-state {
  display: none;
  padding: 20px 10px 10px;
  text-align: center;
}

#job-success-state.is-active {
  display: block;
  animation: fadeIn 0.4s ease;
}

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

.success-badge-icon {
  width: 80px;
  height: 80px;
  background: rgba(205, 164, 94, 0.15);
  border: 2px solid #cda45e;
  color: #cda45e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin: 0 auto 20px;
  box-shadow: 0 0 30px rgba(205, 164, 94, 0.35);
  animation: pulseGold 2s infinite;
}

@keyframes pulseGold {
  0% { box-shadow: 0 0 0 0 rgba(205, 164, 94, 0.5); }
  70% { box-shadow: 0 0 0 16px rgba(205, 164, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(205, 164, 94, 0); }
}

.success-title {
  font-family: var(--heading-font, "Playfair Display", serif);
  font-size: 28px;
  color: #ffffff;
  margin-bottom: 12px;
}

.success-desc {
  color: rgba(255, 255, 255, 0.78);
  font-size: 14.5px;
  line-height: 1.6;
  max-width: 580px;
  margin: 0 auto 25px;
}

/* Candidate Summary Card in Success View */
.application-summary-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(205, 164, 94, 0.25);
  border-radius: 12px;
  padding: 18px 24px;
  max-width: 520px;
  margin: 0 auto 25px;
  text-align: left;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
  font-size: 13.5px;
}

.summary-row:last-child {
  border-bottom: none;
}

.summary-label {
  color: rgba(255, 255, 255, 0.55);
}

.summary-value {
  color: #cda45e;
  font-weight: 600;
}

.btn-complete-job {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #cda45e;
  color: #0c0b09;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 14px 44px;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(205, 164, 94, 0.3);
}

.btn-complete-job:hover {
  background: #ffffff;
  color: #0c0b09;
  transform: translateY(-2px);
}

/* ==========================================================================
   Floating Reopen Badge on Page
   ========================================================================== */
.floating-job-trigger {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 9990;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #141311;
  background: linear-gradient(135deg, #221f1a, #141311);
  color: #cda45e;
  border: 1.5px solid #cda45e;
  padding: 12px 22px;
  border-radius: 50px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(205, 164, 94, 0.25);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.floating-job-trigger i {
  font-size: 18px;
}

.floating-job-trigger:hover {
  background: #cda45e;
  color: #0c0b09;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 14px 40px rgba(205, 164, 94, 0.4);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .job-modal-header {
    padding: 20px 20px 16px;
  }
  .job-modal-title {
    font-size: 21px;
  }
  .job-modal-body {
    padding: 18px 20px 24px;
  }
  .job-modal-card {
    max-height: calc(100vh - 20px);
    border-radius: 12px;
  }
  .chip-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .floating-job-trigger {
    bottom: 15px;
    right: 15px;
    padding: 10px 16px;
    font-size: 13px;
  }
}

/* ==========================================================================
   Multi-Role Position Selector & Cards (Pizzacı, Executive Chef, Garson)
   ========================================================================== */
.position-selection-box {
  background: rgba(205, 164, 94, 0.05);
  border: 1px solid rgba(205, 164, 94, 0.25);
  border-radius: 14px;
  padding: 16px 18px 18px;
  margin-bottom: 22px;
}

.position-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 10px;
}

.position-card {
  position: relative;
  cursor: pointer;
}

.position-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.position-card-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 18px 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  transition: all 0.25s ease;
  height: 100%;
  cursor: pointer;
  position: relative;
  user-select: none;
}

.position-card:hover .position-card-inner {
  border-color: rgba(205, 164, 94, 0.55);
  background: rgba(205, 164, 94, 0.08);
  transform: translateY(-2px);
}

.position-card.is-active .position-card-inner,
.position-card input[type="radio"]:checked + .position-card-inner {
  border-color: #cda45e;
  background: rgba(205, 164, 94, 0.16);
  box-shadow: 0 0 20px rgba(205, 164, 94, 0.22), inset 0 0 15px rgba(205, 164, 94, 0.08);
}

.position-card-icon {
  font-size: 32px;
  line-height: 1;
  margin-bottom: 10px;
  transition: transform 0.25s ease;
}

.position-card:hover .position-card-icon {
  transform: scale(1.1);
}

.position-card-title {
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
  line-height: 1.25;
}

.position-card.is-active .position-card-title,
.position-card input[type="radio"]:checked + .position-card-inner .position-card-title {
  color: #cda45e;
}

.position-card-desc {
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.35;
}

/* Conditional Skills Blocks */
.role-skills-block {
  display: none;
  animation: fadeInRoleBlock 0.35s ease;
}

.role-skills-block.is-visible {
  display: block;
}

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

.text-gold {
  color: #cda45e !important;
}

/* Career Openings Grid on Background Page */
.career-openings-section {
  padding: 40px 0;
  background: #11100e;
  border-top: 1px solid rgba(205, 164, 94, 0.15);
  border-bottom: 1px solid rgba(205, 164, 94, 0.15);
}

.career-openings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 25px;
}

.career-opening-card {
  background: rgba(22, 20, 17, 0.85);
  border: 1px solid rgba(205, 164, 94, 0.25);
  border-radius: 14px;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.3s ease;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
}

.career-opening-card:hover {
  border-color: #cda45e;
  transform: translateY(-4px);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.6), 0 0 25px rgba(205, 164, 94, 0.18);
  color: inherit;
}

.career-opening-card.featured {
  border-color: #cda45e;
  background: linear-gradient(165deg, rgba(35, 30, 22, 0.95), rgba(20, 18, 15, 0.95));
  box-shadow: 0 0 20px rgba(205, 164, 94, 0.15);
}

.career-opening-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.career-opening-icon {
  font-size: 32px;
}

.career-opening-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 10px;
  border-radius: 30px;
  background: rgba(205, 164, 94, 0.12);
  color: #cda45e;
  border: 1px solid rgba(205, 164, 94, 0.3);
}

.career-opening-badge.urgent {
  background: rgba(205, 164, 94, 0.28);
  color: #ffdf9e;
  border-color: #cda45e;
}

.career-opening-title {
  font-family: var(--heading-font, "Playfair Display", serif);
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.career-opening-desc {
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.5;
  margin-bottom: 18px;
}

.career-opening-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(205, 164, 94, 0.15);
  border: 1px solid #cda45e;
  color: #cda45e;
  padding: 10px 18px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.25s ease;
  width: 100%;
}

.career-opening-card:hover .career-opening-btn,
.career-opening-card.featured .career-opening-btn {
  background: #cda45e;
  color: #0c0b09;
}

@media (max-width: 991px) {
  .career-openings-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .position-cards-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .position-card-inner {
    flex-direction: row;
    text-align: left;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
  }
  .position-card-icon {
    font-size: 28px;
    margin-bottom: 0;
  }
}
