/* ================================
   Edit Profile Page
   ================================ */
/* ─── Cards ─── */
.form-card {
	border: none;
	border-radius: 10px;
	box-shadow: var(--shadow-card);
	background: white;
}

.card-section-title {
	font-weight: 600;
	color: var(--navy);
	font-size: 15px;
}

.card-section-icon { color: var(--navy); font-size: 18px; flex-shrink: 0; }

/* ─── Photo upload box ─── */
.photo-box {
	border: 0.863px solid var(--accent-light);
	border-radius: 6px;
	background: white;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 20px 16px;
	gap: 12px;
	min-height: 320px;
}

.photo-preview {
	width: 130px;
	height: 130px;
	border-radius: 50%;
	object-fit: cover;
}

.photo-box-title {
	font-weight: 600;
	color: var(--primary);
	font-size: 13px;
	text-align: center;
}

.photo-change-btn {
	font-weight: 600;
	font-size: 12.94px;
	color: var(--accent);
	border: 0.863px solid var(--accent);
	border-radius: 6px;
	background: white;
	padding: 8px 16px;
	cursor: pointer;
	transition: background-color 0.15s;
}
.photo-change-btn:hover { background: #f0f0ff; }

.photo-formats {
	font-weight: 600;
	color: var(--text-muted);
	font-size: 8.6px;
	text-align: center;
	line-height: 1.6;
}

/* ─── Form fields ─── */
.field-label {
	font-weight: 600;
	font-size: 12px;
	color: var(--navy);
	text-align: right;
	margin-bottom: 8px;
	display: block;
}

.ep-input {
	font-weight: 400;
	font-size: 10px;
	color: #555;
	background: white;
	border: 0.724px solid var(--accent-light);
	border-radius: 5.07px;
	padding: 6.5px 10px;
	width: 100%;
	text-align: right;
	height: 29px;
}

select.ep-input {
	appearance: none;
	padding-left: 28px;
	cursor: pointer;
}

.input-container {
	position: relative;
}

.ep-input-icon {
	position: absolute;
	left: 8px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--primary);
	font-size: 11px;
}

.input-chevron-icon {
	position:absolute;
	left: 8px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--primary);
	font-size: 11px;
	pointer-events: none;
}

.ep-input:focus {
	outline: none;
	border-color: var(--accent);
	box-shadow: 0 0 0 2px rgba(61,66,200,0.15);
}
/* ─── Bio textarea ─── */
.bio-area {
	width: 100%;
	background: rgba(217,217,217,0.13);
	border: 1px solid var(--accent-light);
	border-radius: 6px;
	padding: 12px;
	font-weight: 400;
	font-size: 12.63px;
	color: #555;
	resize: none;
}
.bio-area:focus { outline: none; border-color: var(--accent); }

.char-count {
	font-weight: 400;
	font-size: 11px;
	color: #313030;
}

/* ─── Action buttons ─── */
.btn-save {
	background-color: var(--primary);
	color: #fff;
	font-weight: 600;
	font-size: 10px;
	border: none;
	border-radius: 7px;
	padding: 10px 20px;
	white-space: nowrap;
	transition: background-color 0.15s;
}
.btn-save:hover { background-color: #1e2070; color: #fff; }

.btn-cancel {
	background-color: white;
	color: var(--primary);
	font-weight: 600;
	font-size: 10px !important; 
	border: 1px solid var(--accent-light);
	border-radius: 7px;
	padding: 10px 20px;
	white-space: nowrap;
	transition: background-color 0.15s;
	text-decoration: none;
}
.btn-cancel:hover { background-color: #f8f7ff; }
.btn-save-icon {
  width: 18px;
  height: 18px;
}
@media (max-width: 576px) {
  .btn-cancel, .btn-save {
    padding: 10px 15px !important; 
  }
  .action-btns {
    justify-content: center !important;
  }
  .btn-save-icon {
  width: 15px;
  height: 15px;
  }
}

/* ================================
   Academic Information Page
   ================================ */

/* ── Status card (الوضع الأكاديمي) ──────────────────────── */
.status-card {
	border: none;
	border-radius: 10px;
	box-shadow: var(--shadow-card);
}

.section-label {
	font-family: 'Rubik', sans-serif;
	font-weight: 600;
	color: var(--navy);
	font-size: 15px;
}

.section-icon {
	color: var(--navy);
	font-size: 20px;
}

/* Fields inside status card — select dropdown version */
.ac-field {
	flex: 1 1 0;
	border: 1px solid var(--accent-light);
	border-radius: 7px;
	padding: 13px 10px;
	position: relative;
}

.ac-field-label {
	font-family: 'Rubik', sans-serif;
	font-weight: 600;
	color: var(--primary);
	font-size: 14.4px;
	text-align: right;
	display: block;
	margin-bottom: 2px;
}

/* Wrapper that positions the chevron inside the select area */
.ac-field-select-wrap {
	position: relative;
}

.ac-field-select {
	width: 100%;
	font-family: 'Rubik', sans-serif;
	font-weight: 400;
	font-size: 12.126px;
	color: #555;
	background: transparent;
	border: none;
	outline: none;
	padding: 6px 4px 6px 28px;   /* room for chevron on left (LTR physical = right-start in RTL visual) */
	text-align: right;
	direction: rtl;
	appearance: none;
	-webkit-appearance: none;
	cursor: pointer;
}

/* Custom chevron-down positioned on the left side of the field */
.ac-field-chevron {
	position: absolute;
	left: 4px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--primary);
	font-size: 16px;
	pointer-events: none;
}

@media (max-width: 576px) {
	.dropdown-container {
		flex-direction: column;
	}
}

/* Research Interests: make add row responsive on very small screens */
@media (max-width: 576px) {
  .ri-card .d-flex.align-items-center {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0.5rem;
  }

  .ri-card .btn-add-interest {
    width: 100%;
    padding: 10px 12px;
    box-sizing: border-box;
  }

  .ri-card .interest-input {
    width: 100%;
    box-sizing: border-box;
    min-width: 0; /* prevents flex item overflow */
  }
}

/* ── Degrees section ─────────────────────────────────────── */
.degrees-title {
  font-weight: 600;
  color: var(--primary);
  font-size: 20px;
}

.degrees-sep {
  border: none;
  border-top: 2px solid var(--accent-light);
  margin: 0;
  opacity: 1;
}

/* Add-degree button */
.btn-add-degree {
  background-color: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  border: none;
  border-radius: 7px;
  padding: 9px 25px;
  white-space: nowrap;
  transition: background-color 0.15s;
}

.btn-add-degree:hover {
  background-color: #1e2070;
  color: #fff;
}

/* Degree card */
.degree-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

.degree-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 17px;
  line-height: 2;
}

.degree-subtitle {
  font-weight: 600;
  color: rgba(45, 48, 143, 0.77);
  font-size: 13px;
  line-height: 2;
}

@media (max-width: 576px) {
  .btn-add-degree {
    padding: 9px 10px;
  }
  .degree-title {
    font-size: 15px;
  }
  .degree-subtitle {
    font-size: 10px;
  }
}

.btn-degree-delete {
  background: transparent;
  border: none;
  color: #ff797c;
  font-size: 18px;
  padding: 4px 8px;
  line-height: 1;
  transition: opacity 0.15s;
}
.btn-degree-delete:hover { opacity: 0.75; }

.btn-degree-edit {
  background: transparent;
  border: none;
  color: var(--primary);
  font-size: 18px;
  padding: 4px 8px;
  line-height: 1;
  transition: opacity 0.15s;
}
.btn-degree-edit:hover { opacity: 0.75; }

/* ── Modal Overlay (Backdrop) ─────────────────────────────────── */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.55); /* Darkens background */
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  
  /* Hidden states for transition */
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Active State */
.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ── Modal Popup Box ────────────────────────────────────────── */
.modal-card {
  position: relative;
  background-color: #f9f8f3; /* Matches the light warm cream background in your image */
  border-radius: 16px;
  width: 90%;
  max-width: 620px;
  padding: 32px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  
  /* Pop-up Scale Transition */
  transform: scale(0.85);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

/* ── Close (X) Button ───────────────────────────────────────── */
.close-btn {
  position: absolute;
  top: 18px;
  left: 20px; /* Positions to left edge for RTL layout */
  background: none;
  border: none;
  font-size: 24px;
  color: #555;
  cursor: pointer;
}

/* ── Header Styling ─────────────────────────────────────────── */
.modal-title {
  font-size: 20px;
  font-weight: 700;
  color: #120e43;
  margin: 0 0 4px 0;
  text-align: right;
}

.modal-subtitle {
  font-size: 13px;
  color: #777;
  margin: 0 0 24px 0;
  text-align: right;
}

/* ── Form Layout ────────────────────────────────────────────── */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: #2b2b2b;
  margin-bottom: 6px;
  text-align: right;
}

.required {
  color: #d9534f;
}

.form-input {
  width: 100%;
  height: 42px;
  border: 1px solid #d3d3d3;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  background: #ffffff;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus {
  border-color: #3d42c8;
  box-shadow: 0 0 0 3px rgba(61, 66, 200, 0.15);
}

/* ── Action Buttons ─────────────────────────────────────────── */
.modal-actions {
  display: flex;
  gap: 10px;
}

/* Degree select custom chevron (RTL: place at left end) */
.degree-select-wrap { position: relative; }
.degree-select-wrap select.form-input {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	padding-left: 38px; /* room for chevron on visual end (RTL left) */
}

.degree-select-chevron {
	position: absolute;
	left: 12px; /* left end for RTL */
	top: 70%;
	transform: translateY(-50%);
	pointer-events: none;
	color: var(--primary);
	font-size: 12px;
	padding-left: 5px;
}

.btn-submit {
  background-color: #0d004d;
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.btn-cancel {
  background-color: #ffffff;
  color: #3d42c8;
  border: 1px solid #3d42c8;
  border-radius: 10px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 576px) {
  .form-label {
    font-size: 10px;
  }
  .form-input {
    font-size: 10px;
  }
  .modal-title {
    font-size: 15px;
  }
  .modal-subtitle {
    font-size: 12px;
  }
  .btn-submit {
    font-size: 12px;
  }
  .btn-cancel {
    font-size: 12px;
  }
  
}
/* ================================
   Experiences Page
   ================================ */

.page-subtitle {
  font-weight: 600;
  color: var(--text-muted);
  font-size: 14px;
}

/* Add experience button */
.btn-add-exp {
  background-color: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  border: none;
  border-radius: 7px;
  padding: 9px 25px;
  white-space: nowrap;
  transition: background-color 0.15s;
}
.btn-add-exp:hover,
.btn-add-exp:focus {
  background-color: #1e2070;
  color: #fff;
}

.exp {
	position: relative;
	gap: 18px;
	z-index: 1;
}

/* Separator */
.exp-sep {
  border: none;
  border-top: 2px solid var(--accent-light);
  margin: 0;
  opacity: 1;
}

/* ── Experience card ─────────────────────────────────────── */
.exp-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  position: relative;
}

/* Timeline dot on the visual-left (start) side of the card */
.exp-timeline-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--primary);
  flex-shrink: 0;
	margin-top: 30px;
}

.exp-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 17px;
  line-height: 2;
}

.exp-org {
  font-weight: 600;
  color: rgba(45, 48, 143, 0.5);
  font-size: 13px;
  line-height: 2;
}

/* Date pill */
.date-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background-color: rgba(207, 209, 255, 0.31);
  border-radius: 13px;
  padding: 0 8px;
  font-weight: 600;
  font-size: 9.5px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
}

.date-pill i {
  color: rgba(45, 48, 143, 0.77);
  font-size: 11px;
}

.exp-desc {
  font-weight: 600;
  color: var(--primary);
  font-size: 13px;
  line-height: 2;
	direction: rtl;
}

.exp-btns {
	flex-shrink: 0;
	margin-top: 8px;
}

/* Edit / delete action buttons */
.btn-exp-delete {
  background: transparent;
  border: none;
  color: #ff797c;
  font-size: 18px;
  padding: 4px 6px;
  line-height: 1;
  transition: opacity 0.15s;
}
.btn-exp-delete:hover { opacity: 0.75; }

.btn-exp-edit {
  background: transparent;
  border: none;
  color: var(--primary);
  font-size: 18px;
  padding: 4px 6px;
  line-height: 1;
  transition: opacity 0.15s;
}
.btn-exp-edit:hover { opacity: 0.75; }

/* Timeline vertical line connecting the dots */
.timeline-wrap {
  position: relative;
  padding-left: 16px;
	gap: 18px;
	/* direction: ltr; */
}

.timeline-wrap::before {
  content: '';
  position: absolute;
  /* In RTL, "left" (start) = visual left. The dot column is first child in LTR order here. */
  top: 0;
  bottom: 0;
  right: 5px; /* centre of the 10px dot */
  width: 1px;
  background-color: var(--accent-light);
  z-index: 0;
}

/* ================================
   Research Interests Page
	================================ */

/* Section separator */
.ri-sep {
  border: none;
  border-top: 2px solid var(--accent-light);
  margin: 0;
  opacity: 1;
}

/* ── Add-interest card ───────────────────────────────────── */
.ri-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

.add-card-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 15px;
  line-height: 2;
}

.add-card-subtitle {
  font-weight: 600;
  color: rgba(45, 48, 143, 0.5);
  font-size: 12px;
  line-height: 2;
}

/* Add button */
.btn-add-interest {
  background-color: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  border: none;
  border-radius: 7px;
  padding: 8px 25px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background-color 0.15s;
}
.btn-add-interest:hover { background-color: #1e2070; color: #fff; }

/* Text input */
.interest-input {
  font-weight: 400;
  font-size: 12.63px;
  color: #555;
  border: 1px solid var(--accent-light);
  border-radius: 7px;
  padding: 8px 15px;
  flex: 1 1 0;
}
.interest-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(45, 48, 143, 0.12);
}

/* Suggestion pill (dashed, faded) */
.pill-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px dashed var(--accent-light);
  border-radius: 24px;
  padding: 5px 10px;
  background: transparent;
  font-weight: 600;
  font-size: 10px;
  color: rgba(45, 48, 143, 0.5);
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s;
}
.pill-suggestion:hover { background: rgba(207, 209, 255, 0.18); }

.pill-suggestion .pill-icon {
  font-size: 11px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 1;
}

/* Active interest pill (solid fill, blue) */
.pill-active {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: 24px;
  padding: 3px 8px;
  font-weight: 600;
  font-size: 10px;
  color: var(--accent);
  white-space: nowrap;
  cursor: pointer;
  transition: opacity 0.12s;
}
.pill-active:hover { opacity: 0.82; }

.pill-active .pill-close {
  font-size: 13px;
  line-height: 1;
  flex-shrink: 0;
  color: var(--accent);
}

/* ── Current-interests card ──────────────────────────────── */
.current-card-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 17px;
  line-height: 2;
}

/* ================================
   Preview Profile Page
   ================================ */

  /* ── Profile card ──────────────────────────────────────────── */
.preview-profile-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

/* Photo */
.preview-profile-photo {
  width: 130px;
  height: 130px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

/* Name */
.preview-profile-name {
  font-weight: 600;
  font-size: 17px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 0;
}

/* Position / dept */
.preview-profile-position {
  font-weight: 600;
  font-size: 12px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  margin-bottom: 6px;
}

/* Contact text */
.preview-contact-text {
  font-weight: 600;
  font-size: 11px;
  color: var(--primary);
  margin-bottom: 0;
  overflow-wrap: anywhere;
  word-break: break-all;
}

/* Contact icon */
.preview-contact-icon {
  color: var(--navy);
  font-size: 13px;
  flex-shrink: 0;
}

/* Profile section divider */
.preview-profile-divider {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.09);
  margin: 10px 0;
  opacity: 1;
}

/* Section title */
.preview-section-title {
  font-weight: 600;
  font-size: 14px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 6px;
}

/* Bio text — LTR English */
.preview-bio-text {
  font-weight: 400;
  font-size: 12.63px;
  color: rgba(45, 48, 143, 0.5);
  margin-bottom: 0;
  line-height: 1.7;
}

/* Interest pills */
.preview-interest-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: 24px;
  padding: 3px 9px;
  font-weight: 600;
  font-size: 10px;
  color: var(--accent);
  white-space: nowrap;
  transition: 0.15s;
}

.preview-interest-pill:hover {
  opacity: 0.82;
}

/* Entry rows (degrees, experience, awards) */
.entry-row {
  font-size: 12.63px;
  margin-bottom: 2px;
  line-height: 1.8;
}

.entry-name {
  font-weight: 700;
  color: var(--primary);
}

.entry-sep {
  font-weight: 400;
  color: rgba(45, 48, 143, 0.5);
}

.entry-detail {
  font-weight: 700;
  color: rgba(45, 48, 143, 0.5);
}

/* Supervision project title */
.preview-supervision-title {
  font-weight: 700;
  font-size: 12.63px;
  color: var(--primary);
  line-height: 1.8;
  margin-bottom: 0;
}

/* Supervision meta  */
.preview-supervision-meta {
  font-weight: 700;
  font-size: 12.63px;
  color: rgba(45, 48, 143, 0.5);
  text-align: right;
  margin-bottom: 0;
  line-height: 1.5;
}

/* Research link items — LTR inline (icon to right of text) */
.preview-research-link-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  direction: ltr;
  font-weight: 600;
  font-size: 11px;
  color: var(--primary);
  text-decoration: none;
  line-height: 2;
}

.preview-research-link-item:hover {
  color: var(--primary);
  text-decoration: underline;
}

.preview-research-link-item i {
  color: var(--primary);
  font-size: 11px;
}

@media (max-width: 576px) {
	.preview-profile-header {
		flex-direction: column; 
	}
  .preview-profile-name {
    font-size: 14px;
  }
  .preview-profile-position {
    font-size: 10px;
  }
  .preview-contact-icon {
    font-size: 10px;
  }
  .preview-contact-text {
    font-size: 10px;
  }
}

/* ================================
   Profile Page
   ================================ */
.content-area {
  height: auto;
}

/* ================================
   Settings Page
   ================================ */

/* ── Settings cards ─────────────────────────────────────────── */
.settings-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

/* Section heading (كلمة المرور / خصوصية الملف العام) */
.section-heading {
  font-weight: 600;
  font-size: 15px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 0;
}

.section-icon {
  font-size: 20px;
  color: var(--navy);
  flex-shrink: 0;
}

/* ── Password card inputs ───────────────────────────────────── */
.settings-input-label {
  font-weight: 600;
  font-size: 12px;
  color: var(--navy);
  display: block;
  margin-bottom: 6px;
}

.settings-input-wrap {
  position: relative;
}

.settings-input {
  width: 100%;
  background-color: #fff;
  border: 0.669px solid var(--accent-light);
  border-radius: 5px;
  height: 40px;
  font-weight: 400;
  font-size: 12px;
  color: #555;
  text-align: right;
  padding: 4px 9px 4px 32px; /* right padding for text, left padding for icon */
  line-height: 1;
  flex-shrink: 0;
}

.settings-input::placeholder {
  color: #555;
  font-size: 10px;
}

.settings-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 0.15rem rgba(61, 66, 200, 0.15);
}

/* Lock icon inside input — physical left side */
.settings-input-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--primary);
  font-size: 13px;
  pointer-events: none;
}

/* ── Change password button ─────────────────────────────────── */
.btn-change-pw {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--primary);
  color: #fff;
  border: none;
  border-radius: 7px;
  font-weight: 600;
  font-size: 12px;
  padding: 9px 30px;
  cursor: pointer;
  transition: background-color 0.15s;
}

.btn-change-pw:hover {
  background-color: #1e2070;
}

.btn-change-pw i {
  font-size: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ── Privacy card ───────────────────────────────────────────── */
.privacy-subtitle {
  font-weight: 600;
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
  margin-bottom: 8px;
}

/* Divider between privacy rows */
.privacy-divider {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.09);
  margin: 0;
  opacity: 1;
}

/* Privacy row label */
.setting-label {
  font-weight: 600;
  font-size: 14px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 0;
}

/* Toggle switch — size & ON color */
.privacy-toggle {
  width: 2.75em;
  height: 1.4em;
  cursor: pointer;
  flex-shrink: 0;
}

.privacy-toggle:checked {
  background-color: var(--navy);
  border-color: var(--navy);
}

/* Privacy row container */
.privacy-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}

.settings-eye-btn {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
}

/* ================================
   Published Researches Page
   ================================ */

/* ── Search / filter bar ─────────────────────────────────── */
.search-bar-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

.btn-add-research {
  background-color: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  border: none;
  border-radius: 7px;
  padding: 9px 25px;
  white-space: nowrap;
  flex-shrink: 0;
  height: 40px;
  transition: background-color 0.15s;
  flex: 1 1 0;
}
.btn-add-research:hover { background-color: #1e2070; color: #fff; }

.search-input {
  width: 100%;
	margin-inline-start: auto;
  height: 40px;
  border: 1px solid var(--accent-light);
  border-radius: 7px;
  padding: 8px 15px;
  font-weight: 400;
  font-size: 10px;
  color: #555;
}
.search-input:focus {
  outline: none;
  border-color: #3d42c8;
  box-shadow: 0 0 0 3px rgba(61, 66, 200, 0.15);
}

.search-icon-wrap {
  flex: 1 1 335px;
	/* max-width: 420px; */
	position: relative;
	min-width: 240px;
}

.search-trigger-btn {
	position: absolute;
	left: 5px;
	top: 50%;
	transform: translateY(-50%);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border: none;
	background: transparent;
	padding: 0;
	margin: 0;
	cursor: pointer;
	z-index: 2;
}

.search-trigger-btn i {
	font-size: 1rem;
	color: var(--primary);
	pointer-events: none;
}

/* ── Publication card ───────────────────────────────────────── */
.research-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

/* Type badge (faded light-blue pill) */
.type-badge {
  display: inline-block;
  background: rgba(207, 209, 255, 0.31);
  border-radius: 5px;
  padding: 0 8px;
  font-weight: 600;
  font-size: 10px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  white-space: nowrap;
}

/* Year label */
.year-label {
  font-weight: 600;
  font-size: 10px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  white-space: nowrap;
}

/* Research title */
.research-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 17px;
  line-height: 2;
}

/* Authors / publisher */
.research-meta {
  font-weight: 600;
  color: rgba(45, 48, 143, 0.5);
  font-size: 10px;
  line-height: 2;
  text-align: right;
}

/* Action buttons */
.btn-res-delete {
  background: transparent;
  border: none;
  color: #ff797c;
  font-size: 18px;
  padding: 4px 6px;
  line-height: 1;
  transition: opacity 0.15s;
}

.btn-res-edit {
  background: transparent;
  border: none;
  color: var(--primary);
  font-size: 18px;
  padding: 4px 6px;
  line-height: 1;
  transition: opacity 0.15s;
}

.btn-res-delete:hover, 
.btn-res-edit:hover { opacity: 0.75; }

@media (max-width: 576px) {
  .search-icon-wrap {
    min-width: unset;
    width: 100%;
  }

  .research-title {
    font-size: 12px;
  }
}

/* Select styling used in the search bar filters */
.filter-selects { min-width: 50%; display: flex; align-items: center; gap: 10px; }

.select-wrap { position: relative; display: inline-block; width: 100%; }
.research-select {
  background: #ffffff;
  border: 1px solid var(--accent-light);
  border-radius: 7px;
  padding: 8px 12px;
  height: 40px;
  font-size: 10px;
  color: #333;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  text-align: right;
}
.select-wrap .select-chevron {
  position: absolute;
  left: 10px; /* visual left for RTL layouts */
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--accent);
  font-size: 13px;
}

/* Keep modal form spacing consistent with existing modal styles */
.modal-card .form-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
.modal-card .form-input { height: 44px; }
.modal-overlay { z-index: 1200; }

@media (max-width: 576px) {
  .search-bar-card {
    flex-direction: column;
  }
  .filter-selects { align-items: stretch; width: 100%; }
  .select-wrap { width: 100%; }
  .research-select { width: 100%; }
  .btn-res-edit, .btn-res-delete {
    font-size: 15px;
  }
}

/* ================================
   Research Projects Page
   ================================ */

/* Project card */
.project-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  height: 100%;
}

/* Action icon buttons */
.action-btn {
  background: none;
  border: none;
  padding: 0;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: opacity 0.15s;
}
.action-btn:hover { opacity: 0.7; }
.action-btn.delete-btn { color: var(--red-x); }
.action-btn.edit-btn  { color: var(--primary); }

/* Status badges */
.status-badge {
  font-weight: 600;
  font-size: 10px;
  border-radius: 20px;
  padding: 2px 10px;
  white-space: nowrap;
}
.status-active {
  background-color: #c2ffb3;
  color: #008431;
}
.status-completed {
  background-color: rgba(207, 209, 255, 0.31);
  color: rgba(45, 48, 143, 0.5);
}

/* Project title */
.project-title {
  font-weight: 600;
  font-size: 18px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 4px;
}

/* Project description (muted) */
.project-desc {
  font-weight: 600;
  font-size: 12px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  margin-bottom: 0;
}

/* Card inner divider */
.project-hr {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.09);
  margin: 12px 0;
  opacity: 1;
}

/* Info label/value pairs */
.info-label {
  font-weight: 600;
  font-size: 14px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
}
.info-value {
  font-weight: 600;
  font-size: 12px;
  color: var(--primary);
  line-height: 2;
}

.info-label + .date-pill, .info-label + .date-pill i {
  color: var(--primary);
  font-size: 12px;
}
/* Project link */
.project-link-btn {
  font-weight: 600;
  font-size: 12px;
  color: var(--navy);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  line-height: 2;
}
.project-link-btn:hover { text-decoration: underline; }

@media (max-width: 576px) {
  .project-title {
    font-size: 15px;
  }

  .action-btn {
    font-size: 15px;
  }
  .project-desc {
    font-size: 10px;
  }

  .info-label {
    font-size: 12px;
  }

  .info-value {
    font-size: 10px;
  }
  .info-label + .date-pill, .info-label + .date-pill i {
    font-size: 10px;
  }

  .project-link-btn {
    font-size: 10px;
  }
  
}
/* Project modal specific tweaks */
#project-modal .form-input, #project-modal textarea.form-input {
  height: 44px;
  padding: 10px;
}

#project-modal textarea.form-input { height: auto; min-height: 88px; }

#project-modal .modal-card { max-width: 720px; }

#project-modal .form-grid { grid-template-columns: 1fr 1fr; gap: 12px; }

#project-modal .form-group { margin-bottom: 0; }

/* Disabled fund value visual cue */
#project-fund-value:disabled { background: #f5f5f7; color: #9b9b9b; }

/* Delete-project modal sizing */
#delete-project-modal .modal-card { max-width: 420px; }

/* ================================
   Research Links Page
   ================================ */

/* ── Link card ─────────────────────────────────────────────── */
.link-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  position: relative;
}

/* Link icon square (accent-light bg, rounded square, top-right) */
.link-icon-sq {
  position: absolute;
  top: 23px;
  right: 16px;
  width: 35px;
  height: 35px;
  object-position: center;
  object-fit: cover;
  border-radius: 5px;
  overflow: hidden;
}

/* icon inside the square */
.link-icon-inner {
  width: 100%;
  height: 100%;
}

/* Platform name — right-aligned, padded to avoid icon overlap */
.platform-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--navy);
  text-align: right;
  padding-right: 35px;
  margin-bottom: 0;
}

/* Status row padding keeps elements clear of the icon */
.status-row {
  padding-right: 35px;
  margin-bottom: 8px;
}

/* Status text variants */
.status-connected {
  font-weight: 600;
  font-size: 10px;
  color: rgba(0, 132, 49, 0.75);
}

.status-row:has(.status-connected) i {
  color: rgba(0,132,49,0.75);
  font-size: 12px;
}

.status-disconnected {
  font-weight: 600;
  font-size: 10px;
  color: rgba(255, 0, 0, 0.75);
}

.status-row:has(.status-disconnected) i {
  color: rgba(255, 0, 0, 0.75);
  font-size: 12px;
}

/* URL text (LTR, right-aligned) */
.link-url {
  font-weight: 600;
  font-size: 12px;
  color: #15227b;
  direction: ltr;
  text-align: right;
  word-break: break-all;
  margin-bottom: 12px;
}

/* Description for disconnected cards */
.link-desc {
  font-weight: 600;
  font-size: 12px;
  color: rgba(45, 48, 143, 0.5);
  text-align: right;
  margin-bottom: 12px;
}

/* Edit link button (outlined, accent color) */
.btn-edit-link {
  background-color: #fff;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 7px;
  font-weight: 600;
  font-size: 13px;
  padding: 9px 14px;
  cursor: pointer;
  transition: background-color 0.15s;
}
.btn-edit-link:hover { background-color: rgba(61, 66, 200, 0.06); }

/* Connect button (solid primary) */
.btn-connect {
  background-color: var(--primary);
  color: #fff;
  border: none;
  border-radius: 7px;
  border: 1px solid var(--primary);
  font-weight: 600;
  font-size: 13px;
  padding: 9px 14px;
  cursor: pointer;
  transition: background-color 0.15s;
}
.btn-connect:hover { background-color: #1e2070; }

/* ================================
   Supervision Page
   ================================ */

/* ── Supervision cards ──────────────────────────────────── */
.sup-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

/* Supervision empty state and small tweaks */
.supervision-empty {
  border: 1px dashed var(--accent-light);
  border-radius: 10px;
  padding: 28px;
  text-align: center;
  color: var(--text-muted);
  background: #fff;
  margin-bottom: 12px;
}
.supervision-empty .empty-title { 
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px; 
}
.supervision-empty .empty-sub { font-size: 13px; }

/* Thesis title */
.thesis-title {
  font-weight: 600;
  font-size: 16px;
  color: var(--navy);
  line-height: 2;
  margin-bottom: 2px;
}

/* Role label */
.role-label {
  font-weight: 600;
  font-size: 12px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  white-space: nowrap;
}

/* Student name */
.student-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--navy);
  line-height: 2;
  white-space: nowrap;
}

@media (max-width: 576px) {
  .thesis-title {
    font-size: 12px;
  }

  .role-label {
    font-size: 10px;
  }

  .student-name {
    font-size: 10px;
  }
}

/* ================================
  CV Page
  ================================ */

/* CV Page: empty/active state */
.cv-main-card { 
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  background: white; 
}
.cv-empty { 
  text-align: center;
  padding: 48px 24px;
}

.cv-empty .empty-title {
  font-weight: 600;
  color: var(--navy);
  font-size: 18px; 
}

.cv-empty .empty-sub { 
  color: var(--text-muted);
  font-size: 12px;
}
.cv-empty .btn-add-cv { margin-top: 14px; }

/* CV active state and responsive adjustments */
.cv-active { 
  gap: 12px;
}

.cv-link-card { 
  background: #f8f9ff; 
  border-radius: 8px; 
  padding: 14px 18px; 
  flex: 1 1 auto; 
}

.cv-link { 
  color: var(--primary); 
  font-weight: 600; 
  text-decoration: none; 
  word-break: break-all; 
  display: inline-block;
}

.cv-action-wrap { 
  white-space: nowrap;
}

@media (max-width: 576px) {
  .cv-active { 
    flex-direction: column; 
    align-items: stretch; 
    gap: 12px; 
  }
  .cv-link-card { 
    width: 100%; 
    min-width: 0; 
    padding: 12px; 
    text-align: center;
 }
  .cv-link { 
    font-size: 10px;
  }

  .cv-action-wrap { 
    width: 100%; 
    display: flex; 
    justify-content: center; 
    flex-direction: column;
    gap: 8px; 
  }
  .cv-empty { padding: 32px 12px; }
  .cv-empty > i { font-size: 42px; }
  .cv-empty .empty-title { font-size: 16px; }
  .btn-add-cv { 
    width: 100%; 
    justify-content: center;
  }
}

.btn-remove-cv {
  width: 100%;
}

/* ================================
  Awards Page
  ================================ */

/* ── Award card ──────────────────────── */
.award-card {
  border: none;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  position: relative;
}

/* Trophy icon circle (top-right of card in RTL) */
.award-icon-circle {
  position: absolute;
  top: 22px;
  right: 18px;  /* visual left = top-left in standard CSS = top-right in RTL card */
  width: 35px;
  height: 35px;
  background-color: var(--accent-light);
  border-radius: 50%;
  color: var(--accent);
  font-size: 18px;
  flex-shrink: 0;
}

.award-actions {
  position: absolute;
  top: 22px;
  left: 20px;
}

/* Award title (Arabic) */
.award-title {
  font-weight: 600;
  font-size: 16px;
  color: var(--navy);
  line-height: 2;
  text-align: right;
  margin-bottom: 10px;
  /* leave space for action buttons on the left and icon on the right */
  padding-right: 37px;
  padding-left: 45px; 
  text-wrap: wrap;
}

/* Meta row: institution + separator + year pill */
.award-meta {
  gap: 6px;
}

.bottom-award-actions {
  position: relative;
  left: 0;
  top: 0;
  display: none !important;
}

.institution-text {
  font-weight: 700;
  font-size: 12px;
  color: var(--primary);
  line-height: 2;
  white-space: nowrap;
  text-wrap: wrap;
}

/* Short separator line between institution and year */
.meta-divider {
  display: inline-block;
  width: 12px;
  height: 1px;
  background-color: rgba(45, 48, 143, 0.77);
  flex-shrink: 0;
}
/* Awards empty state */
.award-empty {
  border: 1px dashed var(--accent-light);
  border-radius: 10px;
  padding: 32px;
  text-align: center;
  color: var(--text-muted);
  background: #fff;
  margin-bottom: 12px;
}
.award-empty .empty-title { font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.award-empty .empty-sub { font-size: 13px; }

.award-meta .date-pill, .award-meta .date-pill i {
  color: var(--accent);
  font-size: 12px; 
}

/* Card separator line */
.card-inner-sep {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.09);
  margin: 8px 0;
  opacity: 1;
}

/* Award description */
.award-desc {
  font-weight: 600;
  font-size: 12px;
  color: rgba(45, 48, 143, 0.5);
  line-height: 2;
  margin-bottom: 5px;
}

@media (max-width: 576px) {
  .award-title {
    padding-left: 0;
    font-size: 12px;
  }
  .award-actions {
    display: none !important;
  }
  .bottom-award-actions {
    display: flex !important;
  }
  .institution-text {
    font-size: 10px;
  }
  .award-desc {
    font-size: 10px;
  }
  .award-meta .date-pill, .award-meta .date-pill i {
    font-size: 10px;
  }
}