@charset "UTF-8";
/* ==========================================================================
   academic-profile.css — تنسيقات صفحتَي البروفايل الأكاديمي فقط
   --------------------------------------------------------------------------
   يُحمَّل حصراً في:
       e-learn/show.php     → <body class="academic-directory-page">
       e-learn/profile.php  → <body class="academic-profile-page">

   كل محدِّد هنا مُقيَّد بأحد صنفَي الجسم أعلاه، فلا يتسرّب أي تنسيق إلى
   بقية صفحات نظام التعليم الإلكتروني التي تتشارك css/style2.css
   (‏36 صفحة) أو style/header.css و style/footer.css.

   لا يُستعمل أي مورد خارجي أو CDN: الخط محلي (css/font_1/) والشارة
   محلية (images/uom-accreditation-5stars.svg).

   هوية الألوان: أزرق داكن #0f3b6b · أزرق الجامعة #12467c · ذهبي #c9a227
                 أبيض #ffffff · رمادي فاتح #f4f6f9
   ========================================================================== */


/* --------------------------------------------------------------------------
   1) الخط المحلي — نفس ملف الخط الموجود أصلاً في المشروع
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Droid Arabic Kufi';
  src: url('font_1/DroidArabicKufi.woff2') format('woff2'),
       url('font_1/DroidArabicKufi.woff') format('woff'),
       url('font_1/DroidArabicKufi.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}


/* ==========================================================================
   2) شارة الاعتماد المؤسسي — مكوّن مشترك بين الصفحتين
   ========================================================================== */
/* الشارة شعار رسمي بخلفية شفّافة — بلا أي خلفية أو إطار من CSS.
   نصّ الشعار كان كريمياً فاتحاً (يختفي على البطاقة البيضاء) فأُعيد تلوينه
   إلى الأسود داخل الصورة نفسها، لا بإضافة لوحة داكنة خلفه. */
.academic-directory-page .uom-accred,
.academic-profile-page .uom-accred,
.academic-colleges-page .uom-accred {
  display: inline-block;
  max-width: 100%;
  line-height: 0;
  vertical-align: middle;
}

.academic-directory-page .uom-accred__img,
.academic-profile-page .uom-accred__img,
.academic-colleges-page .uom-accred__img {
  display: block;
  width: 170px;               /* بديل للمتصفّحات بلا clamp() */
  width: clamp(135px, 14vw, 185px);
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

/* نسخة مصغّرة داخل بطاقة التدريسي */
.academic-profile-page .uom-accred--sm .uom-accred__img {
  width: 150px;
  width: clamp(125px, 12.5vw, 165px);
}


/* ==========================================================================
   3) صفحة دليل التدريسيين — show.php
   ========================================================================== */
.academic-directory-page {
  margin: 0;
  padding: 0;
  background: #f4f6f9;
  color: #1f2a37;
  font-family: 'Segoe UI', 'Dubai', Tahoma, Arial, Helvetica, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

.academic-directory-page .ad-wrap,
.academic-directory-page .ad-wrap * {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

.academic-directory-page .ad-wrap {
  width: 100%;
  max-width: 1320px;
  margin: 24px auto 40px;
  padding: 0 16px;
  padding: 0 clamp(12px, 2vw, 26px);
  direction: rtl;
  text-align: right;
}

/* ---- ترويسة الموقع القديمة (style/header.css): تُجعل سائلة داخل هذه
   الصفحة وحدها. الملف مشترك مع صفحات e-learn أخرى فلا يُمسّ. عرضه هناك
   مثبّت بالبكسل (300/470/640/870/970) فيبقى جزيرة ضيّقة على الشاشات
   العريضة ومزدحماً على الضيّقة. ---- */
.academic-directory-page #header,
.academic-directory-page #header * {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

.academic-directory-page #header {
  width: 100%;
  height: auto;
  background: #113b66;
}

.academic-directory-page #h_cont,
.academic-directory-page #h_menu {
  width: 100%;
  max-width: 1320px;
  height: auto;
  margin: 0 auto;
  padding: 0 clamp(10px, 2vw, 26px);
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: horizontal;
  -webkit-box-direction: reverse;
  -ms-flex-direction: row-reverse;
  flex-direction: row-reverse;   /* أول عنصر في DOM يبقى أقصى اليمين */
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

.academic-directory-page #h_cont {
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
  gap: 8px 14px;
  padding-top: 10px;
  padding-bottom: 10px;
  margin-bottom: 3px;
}

.academic-directory-page #h_cont > div { float: none; margin: 0; padding: 0; width: auto; }

.academic-directory-page #h_cont #svg_image > img {
  float: none;
  width: auto;
  max-width: clamp(96px, 17vw, 210px);
  height: auto;
  margin: 0;
  padding: 0;
}

.academic-directory-page #h_cont #logo_image {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 8px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-size: clamp(9px, 1.15vw, 15px);
  line-height: 1.7;
  color: #f9f9f9;
}

.academic-directory-page #h_cont #logo_image > img {
  width: clamp(34px, 4.4vw, 58px);
  height: auto;
  margin: 0;
}

.academic-directory-page #h_cont #logo_image center { text-align: right; }

.academic-directory-page #h_cont #h_text {
  float: none;
  width: auto;
  padding: 0;
  font-size: 12px;
  font-size: clamp(11px, 1.5vw, 26px);
  line-height: 1.25;
  color: #f9f9f9;
}

.academic-directory-page #h_menu {
  -webkit-box-pack: end;
  -ms-flex-pack: end;
  justify-content: flex-end;
  gap: 0;
  background: #000;
  border-bottom: 3px solid #c9a227;
}

.academic-directory-page #h_menu > div {
  float: none;
  padding: 9px 14px;
  font-size: 12px;
  font-size: clamp(11px, 1.15vw, 15px);
  border-right: 1px solid #545454;
  cursor: pointer;
}

.academic-directory-page #h_menu #search {
  float: none;
  margin-right: auto;      /* يُدفع إلى أقصى اليسار في صفٍّ معكوس */
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: nowrap;
  flex-wrap: nowrap;
  min-width: 0;
  padding: 4px 0;
}

.academic-directory-page #h_menu #search > input[type=text] {
  min-width: 0;
  width: clamp(96px, 20vw, 220px);
  height: 30px;
  margin: 0;
  padding: 0 10px;
  font-size: 13px;
}

.academic-directory-page #h_menu #search > input[type=button] {
  height: 30px;
  margin: 0;
  padding: 0 12px;
  font-size: 13px;
  cursor: pointer;
}

/* ---- 3.1 ترويسة المحتوى: الشعار + اسم الكلية + الشارة ---- */
.academic-directory-page .ad-hero {
  position: relative;
  display: block;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-top: 4px solid #12467c;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(15, 59, 107, .07);
  padding: 22px 24px;
  margin-bottom: 18px;
}

.academic-directory-page .ad-hero__eyebrow {
  margin: 0 0 10px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  font-size: clamp(11px, 1.1vw, 13px);
  font-weight: normal;
  line-height: 1.9;
  letter-spacing: 0;
  color: #12467c;
  text-transform: none;
}

.academic-directory-page .ad-hero__eyebrow::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 3px;
  margin-left: 8px;
  border-radius: 2px;
  background: #c9a227;
  vertical-align: middle;
}

.academic-directory-page .ad-hero__grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 18px;
}

.academic-directory-page .ad-hero__logo {
  -ms-flex: 0 0 auto;
  flex: 0 0 auto;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #eef1f6;
  box-shadow: 0 1px 6px rgba(15, 59, 107, .10);
  overflow: hidden;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
}

.academic-directory-page .ad-hero__logo img {
  width: 100%;
  height: 100%;
  -o-object-fit: contain;
  object-fit: contain;
  padding: 6px;
}

.academic-directory-page .ad-hero__id {
  -ms-flex: 1 1 260px;
  flex: 1 1 260px;
  min-width: 0;
}

.academic-directory-page .ad-hero__title {
  margin: 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 22px;
  font-size: clamp(16px, 2.1vw, 24px);
  font-weight: normal;
  line-height: 1.7;
  color: #0f3b6b;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.academic-directory-page .ad-hero__sub {
  margin: 5px 0 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-size: clamp(11px, 1.05vw, 13px);
  font-weight: normal;
  line-height: 1.95;
  color: #5c6b7a;
}

.academic-directory-page .ad-hero__badge {
  -ms-flex: 0 0 auto;
  flex: 0 0 auto;
  padding-right: 18px;
  border-right: 1px dashed #e2e8f0;
}

/* ---- 3.2 شريط الأدوات: اختيار القسم + البحث + العدّاد ---- */
.academic-directory-page .ad-toolbar {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
  gap: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(15, 59, 107, .05);
  padding: 14px 18px;
  margin-bottom: 18px;
}

.academic-directory-page .ad-filter {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.academic-directory-page .ad-filter__label {
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-weight: normal;
  line-height: 1.9;
  color: #0f3b6b;
  margin: 0;
}

.academic-directory-page .ad-select {
  min-width: 220px;
  max-width: 100%;
  height: 42px;
  padding: 0 12px;
  font-family: inherit;
  font-size: 14.5px;
  color: #1f2a37;
  background-color: #ffffff;
  border: 1px solid #cfd8e3;
  border-radius: 9px;
  direction: rtl;
  text-align: right;
  outline: none;
  box-shadow: none;
  -webkit-transition: border-color .18s ease, box-shadow .18s ease;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.academic-directory-page .ad-select:hover { border-color: #9db4cd; }

.academic-directory-page .ad-select:focus {
  border-color: #12467c;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .16);
}

.academic-directory-page .ad-btn {
  height: 42px;
  padding: 0 22px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13.5px;
  font-weight: normal;
  color: #ffffff;
  background: #12467c;
  border: 1px solid #12467c;
  border-radius: 9px;
  cursor: pointer;
  -webkit-transition: background-color .18s ease, box-shadow .18s ease;
  transition: background-color .18s ease, box-shadow .18s ease;
}

.academic-directory-page .ad-btn:hover { background: #0f3b6b; }

.academic-directory-page .ad-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(201, 162, 39, .45);
}

.academic-directory-page .ad-count {
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  line-height: 1.9;
  color: #5c6b7a;
  white-space: nowrap;
}

.academic-directory-page .ad-count b {
  display: inline-block;
  min-width: 34px;
  padding: 2px 10px;
  margin-left: 6px;
  font-size: 13.5px;
  color: #0f3b6b;
  background: #eef3f9;
  border: 1px solid #dbe5f0;
  border-radius: 20px;
  direction: ltr;
}

/* ---- 3.3 شبكة بطاقات التدريسيين ---- */
.academic-directory-page .ad-grid {
  display: grid;
  /* min(...) يمنع تجاوز العمود لعرض الشاشة على أضيق الأجهزة */
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr));
  gap: 16px;
  gap: clamp(10px, 1.4vw, 18px);
  list-style: none;
  margin: 0;
  padding: 0;
}

.academic-directory-page .ad-card {
  list-style: none;
  margin: 0;
  padding: 0;
}

.academic-directory-page .ad-card__link {
  display: block;
  height: 100%;
  padding: 18px 14px 16px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 1px 4px rgba(15, 59, 107, .05);
  -webkit-transition: box-shadow .18s ease, border-color .18s ease, -webkit-transform .18s ease;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.academic-directory-page .ad-card__link:hover,
.academic-directory-page .ad-card__link:focus {
  text-decoration: none;
  color: inherit;
  border-color: #c9a227;
  box-shadow: 0 6px 18px rgba(15, 59, 107, .12);
  -webkit-transform: translateY(-2px);
  transform: translateY(-2px);
}

.academic-directory-page .ad-card__link:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .22), 0 6px 18px rgba(15, 59, 107, .12);
}

.academic-directory-page .ad-card__media {
  display: block;
  width: 104px;
  height: 104px;
  margin: 0 auto 12px;
  border-radius: 50%;
  overflow: hidden;
  background: #eef1f6;
  border: 3px solid #ffffff;
  box-shadow: 0 0 0 2px #e2e8f0;
}

.academic-directory-page .ad-card__link:hover .ad-card__media {
  box-shadow: 0 0 0 2px #c9a227;
}

.academic-directory-page .ad-card__img {
  display: block;
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
  object-fit: cover;
  -o-object-position: center top;
  object-position: center top;
}

.academic-directory-page .ad-card__rank {
  display: block;
  margin-bottom: 3px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12px;
  font-weight: normal;
  line-height: 1.9;
  color: #12467c;
}

.academic-directory-page .ad-card__name {
  display: block;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.85;
  color: #1f2a37;
  word-wrap: break-word;
  overflow-wrap: break-word;
  -ms-word-break: break-word;
  word-break: break-word;
  hyphens: auto;
}

/* ---- 3.4 حالة اللا-نتائج ---- */
.academic-directory-page .ad-empty {
  background: #ffffff;
  border: 1px dashed #cfd8e3;
  border-radius: 14px;
  padding: 46px 20px;
  text-align: center;
  color: #5c6b7a;
}

.academic-directory-page .ad-empty__title {
  margin: 0 0 6px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 17px;
  font-weight: normal;
  color: #0f3b6b;
}

.academic-directory-page .ad-empty__text {
  margin: 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  line-height: 2;
}

/* ---- 3.5 ترقيم الصفحات ---- */
.academic-directory-page .ad-pagination {
  margin-top: 22px;
  padding: 14px 10px;
  text-align: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  direction: rtl;
}

.academic-directory-page .ad-pagination:empty { display: none; }

.academic-directory-page .ad-pagination a,
.academic-directory-page .ad-pagination .ad-page-current {
  display: inline-block;
  min-width: 40px;
  margin: 3px 4px;
  padding: 7px 12px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 9px;
  -webkit-transition: background-color .18s ease, color .18s ease;
  transition: background-color .18s ease, color .18s ease;
}

.academic-directory-page .ad-pagination a {
  color: #12467c;
  background: #eef3f9;
  border: 1px solid #dbe5f0;
}

.academic-directory-page .ad-pagination a:hover {
  background: #12467c;
  color: #ffffff;
  border-color: #12467c;
}

.academic-directory-page .ad-pagination a:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .22);
}

.academic-directory-page .ad-pagination .ad-page-current {
  color: #ffffff;
  background: #12467c;
  border: 1px solid #12467c;
}

/* ---- 3.6 التذييل: إلغاء التثبيت حتى لا يغطي المحتوى ---- */
.academic-directory-page #footer,
.academic-directory-page #footer * {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

.academic-directory-page #footer {
  position: static;
  width: 100%;
  height: auto;
  padding: 14px 12px;
  background: #0f3b6b;
  border-top: 3px solid #c9a227;
  box-shadow: none;
}

.academic-directory-page #footer #Fcont {
  width: 100%;
  max-width: 900px;
  font-size: 13px;
}

/* ---- 3.7 الاستجابة ---- */
@media only screen and (max-width: 991px) {
  .academic-directory-page .ad-hero__badge {
    -ms-flex: 1 1 100%;
    flex: 1 1 100%;
    padding-right: 0;
    padding-top: 16px;
    margin-top: 4px;
    border-right: 0;
    border-top: 1px dashed #e2e8f0;
    text-align: center;
  }
}

@media only screen and (max-width: 767px) {
  .academic-directory-page .ad-wrap { margin-top: 16px; padding: 0 12px; }
  .academic-directory-page .ad-hero { padding: 18px 16px; }
  .academic-directory-page .ad-hero__title { font-size: 19px; }
  .academic-directory-page .ad-toolbar {
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    -webkit-box-align: stretch;
    -ms-flex-align: stretch;
    align-items: stretch;
  }
  .academic-directory-page .ad-filter { width: 100%; }
  .academic-directory-page .ad-filter__label { -ms-flex: 0 0 100%; flex: 0 0 100%; }
  .academic-directory-page .ad-select { -ms-flex: 1 1 auto; flex: 1 1 auto; min-width: 0; }
  .academic-directory-page .ad-btn { -ms-flex: 0 0 auto; flex: 0 0 auto; padding: 0 18px; }
  .academic-directory-page .ad-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .academic-directory-page .ad-card__media { width: 88px; height: 88px; }
  .academic-directory-page .ad-card__name { font-size: 13px; }
}

@media only screen and (max-width: 480px) {
  .academic-directory-page .ad-hero__grid {
    gap: 12px;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    text-align: center;
  }
  .academic-directory-page .ad-hero__logo { width: 76px; height: 76px; }
  .academic-directory-page .ad-hero__id { -ms-flex: 1 1 100%; flex: 1 1 100%; text-align: center; }
  .academic-directory-page .ad-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media only screen and (max-width: 360px) {
  .academic-directory-page .ad-wrap { padding: 0 10px; }
  .academic-directory-page .ad-hero { padding: 14px 12px; }
  .academic-directory-page .ad-toolbar { padding: 12px; }
  .academic-directory-page .ad-card__link { padding: 14px 8px 12px; }
  .academic-directory-page .ad-card__media { width: 74px; height: 74px; margin-bottom: 9px; }
  .academic-directory-page .ad-card__name { font-size: 12px; line-height: 1.75; }
  .academic-directory-page .ad-pagination a,
  .academic-directory-page .ad-pagination .ad-page-current {
    min-width: 34px; padding: 6px 9px; font-size: 13px; margin: 3px 2px;
  }
}


/* ==========================================================================
   4) صفحة البروفايل الأكاديمي — profile.php
   ========================================================================== */
.academic-profile-page {
  background: #f4f6f9;
  color: #1f2a37;
  overflow-x: hidden;
}

.academic-profile-page .ap-scope,
.academic-profile-page .ap-scope * {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

/* الحاويات الثلاث كانت 83% من عرض الشاشة مهما بلغ: جزيرة ضيّقة على
   الجوّال وشريط ممتدّ بلا حدّ على الشاشات العريضة. تصير سائلة بسقف. */
.academic-profile-page .pord,
.academic-profile-page .pord_2,
.academic-profile-page .pord_3 {
  width: 94%;
  width: min(94%, 1320px);
  max-width: 1320px;
}

/* الإطار الداكن الأصلي محفوظ: البطاقات البيضاء تطفو فوقه */
.academic-profile-page .pord {
  background: #333333;
  border-top: 4px solid #c9a227;
  border-radius: 0 0 14px 14px;
  box-shadow: 0 6px 22px rgba(0, 0, 0, .22);
  padding-top: 4px;
  padding-bottom: 26px;
}

.academic-profile-page .pord .hr1 { display: none; }

/* ---- 4.1 بطاقة التعريف ---- */
.academic-profile-page .ap-card {
  direction: rtl;
  text-align: right;
  background: #ffffff;
  border: 1px solid #ffffff;
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .20);
  padding: 22px;
  margin: 18px 0 20px;
  font-family: 'Segoe UI', 'Dubai', Tahoma, Arial, Helvetica, sans-serif;
}

/* شبكة البطاقة: الصورة عمود يمينيّ يمتدّ على صفّين، والاسم والشارة في
   الصفّ الأول، والتفاصيل تلتصق مباشرة تحت الاسم بلا فجوة ميتة.
   وعلى الهاتف تُعاد ترتيب المناطق: الشارة أولاً فوق الصورة. */
.academic-profile-page .ap-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas:
    "media id      badge"
    "media details details";
  gap: 4px 20px;
  -webkit-box-align: start;
  -ms-flex-align: start;
  align-items: start;
}

.academic-profile-page .ap-card__media  { grid-area: media; }
.academic-profile-page .ap-card__id     { grid-area: id; }
.academic-profile-page .ap-card__badge  { grid-area: badge; }
.academic-profile-page .ap-card__details{ grid-area: details; }

.academic-profile-page .ap-card__media {
  width: 148px;
  text-align: center;
}

.academic-profile-page .ap-photo {
  display: block;
  width: 148px;
  height: 178px;
  -o-object-fit: cover;
  object-fit: cover;
  -o-object-position: center top;
  object-position: center top;
  background: #eef1f6;
  border: 3px solid #ffffff;
  border-radius: 12px;
  box-shadow: 0 0 0 2px #dbe5f0, 0 3px 10px rgba(15, 59, 107, .10);
  margin: 0 auto;
}

.academic-profile-page .ap-meta {
  margin: 10px 0 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12px;
  line-height: 1.95;
  color: #5c6b7a;
  direction: rtl;
}

.academic-profile-page .ap-meta span { display: block; }

.academic-profile-page .ap-retired {
  display: inline-block;
  margin-top: 4px;
  padding: 3px 11px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 11px;
  line-height: 1.9;
  color: #7a5a00;
  background: #fdf6e3;
  border: 1px solid #eddfae;
  border-radius: 20px;
}

.academic-profile-page .ap-card__id {
  min-width: 0;
}

/* الشارة عنصر ثالث في صفّ البطاقة: الصورة يميناً، الاسم وسطاً، الشارة
   يساراً. كونها شقيقة مباشرة يسمح بترتيبها بـorder على الهاتف. */
.academic-profile-page .ap-card__badge {
  padding-top: 2px;
  justify-self: end;          /* أقصى اليسار في سياق RTL */
}

.academic-profile-page .ap-card__details {
  margin-top: 10px;
}

.academic-profile-page .ap-name {
  margin: 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 21px;
  font-size: clamp(16px, 1.95vw, 23px);
  font-weight: normal;
  line-height: 1.75;
  color: #0f3b6b;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* الكلية والقسم بنفس الخط الكوفي المحلي المستعمل في الاسم والعناوين.
   وزن عادي: للخط وجهٌ واحد، وفرضُ bold عليه يولّد تعريضاً صناعياً مشوّهاً.
   التدرّج يقوم على الحجم واللون بدل الوزن. */
.academic-profile-page .ap-title {
  margin: 7px 0 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 14.5px;
  font-size: clamp(12.5px, 1.25vw, 15px);
  font-weight: normal;
  line-height: 1.95;
  color: #12467c;
}

.academic-profile-page .ap-affil {
  margin: 3px 0 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-size: clamp(11.5px, 1.05vw, 13px);
  font-weight: normal;
  line-height: 1.95;
  color: #5c6b7a;
}

/* قائمة معلومات الاتصال */
.academic-profile-page .ap-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr));
  gap: 8px 18px;
  margin: 16px 0 0;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1px solid #eef1f6;
  border-radius: 10px;
}

.academic-profile-page .ap-fact {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 13.5px;
  line-height: 1.9;
  min-width: 0;
}

.academic-profile-page .ap-fact__k {
  -ms-flex: 0 0 auto;
  flex: 0 0 auto;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  font-weight: normal;
  color: #5c6b7a;
}

.academic-profile-page .ap-fact__k::after { content: ":"; margin-right: 1px; }

.academic-profile-page .ap-fact__v {
  min-width: 0;
  color: #1f2a37;
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-word;
}

.academic-profile-page .ap-fact__v a { color: #12467c; text-decoration: none; }
.academic-profile-page .ap-fact__v a:hover { text-decoration: underline; }
.academic-profile-page .ap-fact__v--ltr { direction: ltr; unicode-bidi: embed; display: inline-block; }

/* روابط المنصّات العلمية */
.academic-profile-page .ap-links {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.academic-profile-page .ap-links__label {
  -ms-flex: 0 0 100%;
  flex: 0 0 100%;
  margin: 0 0 3px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12px;
  font-weight: normal;
  line-height: 1.9;
  color: #5c6b7a;
}

.academic-profile-page .ap-links > li {
  list-style: none;
  min-width: 0;
  margin: 0;
  padding: 0;
}

.academic-profile-page .ap-link {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  font-size: 12.5px;
  font-weight: 700;
  color: #12467c;
  text-decoration: none;
  background: #ffffff;
  border: 1px solid #dbe5f0;
  border-radius: 22px;
  -webkit-transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
  transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.academic-profile-page .ap-link:hover {
  text-decoration: none;
  color: #0f3b6b;
  background: #eef3f9;
  border-color: #c9a227;
}

.academic-profile-page .ap-link:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .22);
}

.academic-profile-page .ap-link img {
  width: 18px;
  height: 18px;
  -o-object-fit: contain;
  object-fit: contain;
}

/* ---- 4.2 التبويبات ---- */
.academic-profile-page .tabbed {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  gap: 6px;
  direction: rtl;
}

.academic-profile-page .tabbed > input { display: none; }

.academic-profile-page .tabbed > label {
  -webkit-box-flex: 1;
  -ms-flex: 1 1 auto;
  flex: 1 1 auto;
  float: none;
  width: auto;
  min-width: 0;
  margin: 0;
  padding: 11px 14px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
  /* التبويب غير النشط باهت فوق الإطار الداكن، والنشط أبيض يندمج مع
     لوحته — التدرّج البصري الصحيح: الأبرز هو المحتوى المفتوح. */
  color: #e6ecf3;
  background: rgba(255, 255, 255, .13);
  border: 1px solid rgba(255, 255, 255, .16);
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
  cursor: pointer;
  -webkit-transition: background-color .18s ease, color .18s ease;
  transition: background-color .18s ease, color .18s ease;
}

.academic-profile-page .tabbed > label:hover {
  background: rgba(255, 255, 255, .24);
  color: #ffffff;
}

.academic-profile-page .tabbed > input:checked + label {
  color: #0f3b6b;
  background: #ffffff;
  border-color: #ffffff;
  border-top: 3px solid #c9a227;
  padding-top: 9px;
}

.academic-profile-page .tabbed > input:focus + label {
  box-shadow: 0 0 0 3px rgba(201, 162, 39, .45);
}

/* الألواح تعود إلى السريان الطبيعي: لا ارتفاع محسوب ولا تغطية للتذييل */
.academic-profile-page .tabs {
  -ms-flex: 0 0 100%;
  flex: 0 0 100%;
  clear: both;
  perspective: none;
  position: relative;
  width: 100%;
}

.academic-profile-page #wrapper {
  height: auto !important;
  min-height: 0 !important;
}

.academic-profile-page .tabs > div {
  position: static;
  display: none;
  width: 100%;
  opacity: 1;
  -webkit-transform: none;
  transform: none;
  -webkit-transition: none;
  transition: none;
  background: #ffffff;
  border: 1px solid #ffffff;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .18);
  padding: 6px 20px 22px;
  text-align: right;
  direction: rtl;
  line-height: 1.8;
}

/* الجداول تعود إلى اتجاه المستند الأصلي (LTR) فيبقى ترتيب الأعمدة كما
   اعتاده المستخدم: «ت» أقصى اليمين و«رابط البحث» أقصى اليسار. جعلُ اللوح
   RTL كان يعكس ترتيب الأعمدة كلّه. */
.academic-profile-page .tabs .table-responsive,
.academic-profile-page .tabs table.table {
  direction: ltr;
}

.academic-profile-page #tab-nav-1:checked ~ .tabs > div:nth-of-type(1),
.academic-profile-page #tab-nav-2:checked ~ .tabs > div:nth-of-type(2),
.academic-profile-page #tab-nav-3:checked ~ .tabs > div:nth-of-type(3),
.academic-profile-page #tab-nav-4:checked ~ .tabs > div:nth-of-type(4),
.academic-profile-page #tab-nav-5:checked ~ .tabs > div:nth-of-type(5) {
  display: block;
  opacity: 1;
  z-index: 1;
  -webkit-animation: apFadeIn .22s ease both;
  animation: apFadeIn .22s ease both;
}

@-webkit-keyframes apFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes apFadeIn { from { opacity: 0; } to { opacity: 1; } }

.academic-profile-page .tabs > div > h3 {
  margin: 18px 0 12px;
  padding-bottom: 10px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 17px;
  font-weight: normal;
  color: #0f3b6b;
  border-bottom: 1px solid #eef1f6;
}

.academic-profile-page .p_text {
  font-size: 15px;
  line-height: 2;
  color: #1f2a37;
}

.academic-profile-page .hr2 {
  border: 0;
  border-top: 1px solid #eef1f6;
  margin: 18px 0 14px;
}

/* شريط أسفل كل لوح */
.academic-profile-page .fot {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 10px;
  margin: 0;
  direction: rtl;
}

.academic-profile-page .ap-visits {
  display: -webkit-inline-box;
  display: -ms-inline-flexbox;
  display: inline-flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 8px;
  padding: 7px 15px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  font-weight: normal;
  line-height: 1.9;
  color: #0f3b6b;
  background: #eef3f9;
  border: 1px solid #dbe5f0;
  border-radius: 22px;
}

.academic-profile-page .ap-visits b { direction: ltr; font-weight: normal; }

.academic-profile-page .but_details {
  padding: 6px 16px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  color: #ffffff;
  background: #12467c;
  border: 1px solid #12467c;
  border-radius: 22px;
  margin: 0;
  -webkit-transition: background-color .18s ease;
  transition: background-color .18s ease;
}

.academic-profile-page .but_details:hover { background: #0f3b6b; }
.academic-profile-page .but_details:focus { outline: none; box-shadow: 0 0 0 3px rgba(201, 162, 39, .45); }
.academic-profile-page .but_details > a { color: #ffffff; text-decoration: none; }

.academic-profile-page .but_downloading {
  padding: 7px 16px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  color: #7a5a00;
  background: #fdf6e3;
  border: 1px solid #e2c667;
  border-radius: 22px;
  float: left;
  margin-top: 16px;
}

.academic-profile-page .but_downloading:hover {
  color: #ffffff;
  background: #c9a227;
  border-color: #c9a227;
}

.academic-profile-page .but_downloading > a { color: inherit; text-decoration: none; }

.academic-profile-page .but_download {
  height: 30px;
  width: 30px;
  padding: 3px;
  color: #12467c;
  background: #eef3f9;
  border: 1px solid #dbe5f0;
  border-radius: 50%;
  -webkit-transition: background-color .18s ease, color .18s ease;
  transition: background-color .18s ease, color .18s ease;
}

.academic-profile-page .but_download:hover { background: #12467c; }
.academic-profile-page .but_download:hover > a { color: #ffffff; }
.academic-profile-page .but_download > a { color: #12467c; text-decoration: none; }
.academic-profile-page .but_download:focus { outline: none; box-shadow: 0 0 0 3px rgba(18, 70, 124, .22); }

/* ---- 4.3 الجداول ---- */
.academic-profile-page .table-responsive {
  -webkit-overflow-scrolling: touch;
  border: 0;
}

.academic-profile-page .tabs table.table {
  margin-bottom: 0;
  background: #ffffff;
  border-color: #e2e8f0;
}

.academic-profile-page .tabs table.table > thead > tr > td,
.academic-profile-page .tabs table.table > tbody > tr > td {
  border-color: #e8edf3;
  vertical-align: middle;
  font-size: 13px;
  padding: 9px 10px;
}

.academic-profile-page .thead {
  background: #12467c;
  color: #ffffff;
  border-bottom: 3px solid #c9a227;
  font-size: 13px;
}

.academic-profile-page .thead > tr > td { color: #ffffff; }

.academic-profile-page .tabs table.table-hover > tbody > tr:hover { background-color: #f4f8fc; }

/* ---- 4.4 السيرة الذاتية (PDF) ---- */
.academic-profile-page .pdf {
  width: 100%;
  height: 78vh;
  min-height: 420px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}

/* ---- 4.5 المحاضرات الفيديوية ---- */
.academic-profile-page #d5 .thumbnail {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  background: #ffffff;
  -webkit-transition: box-shadow .18s ease, border-color .18s ease;
  transition: box-shadow .18s ease, border-color .18s ease;
}

.academic-profile-page #d5 .thumbnail:hover {
  border-color: #c9a227;
  box-shadow: 0 6px 18px rgba(15, 59, 107, .12);
}

.academic-profile-page #d5 a.thumbnail:focus {
  outline: none;
  border-color: #c9a227;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .22);
}

/* محاضرة فيديوية برابط غير صالح: تُعرض ولا تكون قابلة للنقر */
.academic-profile-page #d5 .thumbnail--nolink {
  cursor: default;
  opacity: .72;
}

.academic-profile-page #d5 .thumbnail--nolink:hover {
  border-color: #e2e8f0;
  box-shadow: none;
}

.academic-profile-page #d5 .caption { padding: 14px 14px 16px; }

.academic-profile-page #d5 .caption h4 {
  margin: 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 13.5px;
  line-height: 1.9;
  color: #0f3b6b;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* ---- 4.6 التذييل: إلغاء التثبيت ---- */
.academic-profile-page footer {
  position: static;
  width: 100%;
  margin-top: 30px;
  padding: 14px 12px;
  background: #0f3b6b;
  border-top: 3px solid #c9a227;
  color: #ffffff;
}

.academic-profile-page footer a,
.academic-profile-page footer #programmer {
  color: #ffffff;
  text-decoration: none;
  font-size: 13px;
}

.academic-profile-page footer a:hover { text-decoration: underline; }

/* ---- 4.7 الاستجابة ---- */
@media only screen and (max-width: 767px) {
  .academic-profile-page .ap-card { padding: 16px; margin: 14px 0 16px; }
  /* على الهاتف: الشارة أولاً فوق الصورة، ثم الصورة، ثم الاسم، ثم التفاصيل */
  .academic-profile-page .ap-card {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "badge"
      "media"
      "id"
      "details";
    justify-items: center;
    gap: 12px 0;
    text-align: center;
  }
  .academic-profile-page .ap-card__id { text-align: center; width: 100%; }
  .academic-profile-page .ap-card__details { width: 100%; margin-top: 0; }
  .academic-profile-page .ap-card__badge {
    justify-self: center;
    width: 100%;
    padding-top: 0;
    text-align: center;
  }
  .academic-profile-page .ap-name { font-size: 18px; }
  .academic-profile-page .ap-links { -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; }
  .academic-profile-page .ap-links__label { text-align: center; }
  .academic-profile-page .ap-facts { text-align: right; }
  .academic-profile-page .tabbed > label { -ms-flex: 1 1 46%; flex: 1 1 46%; font-size: 12px; padding: 10px 8px; }
  .academic-profile-page .tabs > div { padding: 6px 12px 18px; }
  .academic-profile-page .pdf { height: 60vh; min-height: 320px; }
  .academic-profile-page .fot { -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; }
  .academic-profile-page .but_downloading { float: none; display: inline-block; }
}

@media only screen and (max-width: 480px) {
  .academic-profile-page .ap-photo { width: 128px; height: 154px; }
  .academic-profile-page .ap-card__media { width: 128px; }
  .academic-profile-page .tabbed > label { -ms-flex: 1 1 100%; flex: 1 1 100%; }
}

@media only screen and (max-width: 360px) {
  .academic-profile-page .pord,
  .academic-profile-page .pord_2,
  .academic-profile-page .pord_3 { width: 97%; }
  .academic-profile-page .ap-card { padding: 13px 11px; }
  .academic-profile-page .ap-facts { padding: 11px 12px; }
  .academic-profile-page .ap-fact { font-size: 12.5px; }
  .academic-profile-page .ap-link { padding: 6px 10px; font-size: 11.5px; }
  .academic-profile-page .tabs > div { padding: 4px 9px 16px; }
  .academic-profile-page .tabs > div > h3 { font-size: 15px; }
  .academic-profile-page .p_text { font-size: 14px; }
  .academic-profile-page .pdf { height: 52vh; min-height: 280px; }
}


/* ==========================================================================
   5) صفحة الكليات — colleges.php
   ========================================================================== */
.academic-colleges-page {
  background: #f4f6f9;
  color: #1f2a37;
  font-family: 'Segoe UI', 'Dubai', Tahoma, Arial, Helvetica, sans-serif;
  overflow-x: hidden;
}

.academic-colleges-page .ac-wrap,
.academic-colleges-page .ac-wrap * {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

.academic-colleges-page .ac-wrap {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 24px 16px 40px;
  padding: 24px clamp(12px, 2vw, 26px) 40px;
  direction: rtl;
  text-align: right;
}

/* ---- 5.1 الترويسة ---- */
.academic-colleges-page .ac-hero {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-top: 4px solid #12467c;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(15, 59, 107, .07);
  padding: 22px 24px;
  margin-bottom: 18px;
}

.academic-colleges-page .ac-hero__grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  gap: 18px;
}

.academic-colleges-page .ac-hero__logo {
  -ms-flex: 0 0 auto;
  flex: 0 0 auto;
}

.academic-colleges-page .ac-hero__logo img {
  display: block;
  width: 96px;
  width: clamp(72px, 8vw, 108px);
  height: auto;
}

.academic-colleges-page .ac-hero__id {
  -ms-flex: 1 1 260px;
  flex: 1 1 260px;
  min-width: 0;
}

.academic-colleges-page .ac-hero__eyebrow {
  margin: 0 0 6px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12px;
  font-size: clamp(11px, 1.1vw, 13px);
  line-height: 1.9;
  color: #12467c;
}

.academic-colleges-page .ac-hero__eyebrow::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 3px;
  margin-left: 8px;
  border-radius: 2px;
  background: #c9a227;
  vertical-align: middle;
}

.academic-colleges-page .ac-hero__title {
  margin: 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 21px;
  font-size: clamp(16px, 2.1vw, 24px);
  font-weight: normal;
  line-height: 1.7;
  color: #0f3b6b;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.academic-colleges-page .ac-hero__sub {
  margin: 5px 0 0;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  font-size: clamp(11px, 1.05vw, 13px);
  line-height: 1.95;
  color: #5c6b7a;
}

.academic-colleges-page .ac-hero__badge {
  -ms-flex: 0 0 auto;
  flex: 0 0 auto;
  padding-right: 18px;
  border-right: 1px dashed #e2e8f0;
}

/* ---- 5.2 البحث الفوري ---- */
.academic-colleges-page .ac-search {
  position: relative;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(15, 59, 107, .05);
  padding: 14px 18px;
  margin-bottom: 16px;
  z-index: 20;
}

.academic-colleges-page .ac-search__label {
  display: block;
  margin: 0 0 7px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  font-weight: normal;
  line-height: 1.9;
  color: #0f3b6b;
}

.academic-colleges-page .ac-search__field {
  position: relative;
}

.academic-colleges-page .ac-search__input {
  display: block;
  width: 100%;
  height: 44px;
  padding: 0 14px 0 42px;
  font-family: inherit;
  font-size: 15px;
  color: #1f2a37;
  background: #ffffff;
  border: 1px solid #cfd8e3;
  border-radius: 10px;
  direction: rtl;
  text-align: right;
  outline: none;
  -webkit-transition: border-color .18s ease, box-shadow .18s ease;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.academic-colleges-page .ac-search__input:hover { border-color: #9db4cd; }

.academic-colleges-page .ac-search__input:focus {
  border-color: #12467c;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .16);
}

.academic-colleges-page .ac-search__icon {
  position: absolute;
  top: 50%;
  left: 14px;
  margin-top: -9px;
  line-height: 0;
  color: #8a9bad;
  pointer-events: none;
}

/* نافذة نتائج البحث المنسدلة (‏محتواها من live_search.php) */
.academic-colleges-page #searchLog {
  display: none;
  position: absolute;
  top: 100%;
  right: 18px;
  left: 18px;
  z-index: 100;
  max-height: 60vh;
  overflow-y: auto;
  background: #ffffff;
  border: 1px solid #dbe5f0;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 12px 28px rgba(15, 59, 107, .18);
}

.academic-colleges-page #searchLog table.table {
  margin: 0;
  background: #ffffff;
  direction: rtl;
}

.academic-colleges-page #searchLog table.table > thead > tr > th {
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12px;
  font-weight: normal;
  color: #ffffff;
  text-align: right;
  background: #12467c;
  border-bottom: 2px solid #c9a227;
  padding: 9px 12px;
}

.academic-colleges-page #searchLog table.table > tbody > tr > td {
  font-size: 13px;
  vertical-align: middle;
  text-align: right;
  border-color: #eef1f6;
  padding: 8px 12px;
}

.academic-colleges-page #searchLog table.table > tbody > tr:hover { background: #f4f8fc; }

.academic-colleges-page #searchLog table.table img {
  width: 46px;
  height: 46px;
  -o-object-fit: cover;
  object-fit: cover;
  -o-object-position: center top;
  object-position: center top;
  border-radius: 50%;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px #dbe5f0;
}

/* ---- 5.3 عدّاد الكليات ---- */
.academic-colleges-page .ac-count {
  margin: 0 0 12px;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 12.5px;
  line-height: 1.9;
  color: #5c6b7a;
}

.academic-colleges-page .ac-count b {
  display: inline-block;
  min-width: 32px;
  padding: 2px 10px;
  margin-right: 6px;
  font-weight: normal;
  color: #0f3b6b;
  background: #eef3f9;
  border: 1px solid #dbe5f0;
  border-radius: 20px;
  direction: ltr;
}

/* ---- 5.4 شبكة الكليات ---- */
.academic-colleges-page .ac-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr));
  gap: 16px;
  gap: clamp(10px, 1.4vw, 18px);
  list-style: none;
  margin: 0;
  padding: 0;
}

.academic-colleges-page .ac-card { list-style: none; margin: 0; padding: 0; }

.academic-colleges-page .ac-card__link {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  height: 100%;
  padding: 20px 14px 18px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 1px 4px rgba(15, 59, 107, .05);
  -webkit-transition: box-shadow .18s ease, border-color .18s ease, -webkit-transform .18s ease;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.academic-colleges-page .ac-card__link:hover,
.academic-colleges-page .ac-card__link:focus {
  text-decoration: none;
  color: inherit;
  border-color: #c9a227;
  box-shadow: 0 6px 18px rgba(15, 59, 107, .12);
  -webkit-transform: translateY(-2px);
  transform: translateY(-2px);
}

.academic-colleges-page .ac-card__link:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(18, 70, 124, .22), 0 6px 18px rgba(15, 59, 107, .12);
}

/* الشعارات متباينة الأشكال والنسب: contain لا cover، فلا يُقتطع منها شيء */
.academic-colleges-page .ac-card__media {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
  width: 104px;
  height: 104px;
  margin: 0 auto 14px;
  padding: 9px;
  /* أرضية رمادية فاتحة جداً: تُطوّق الشعارات ذات الخلفية البيضاء فلا
     تذوب في بياض البطاقة، وتخفّف حدّة الشعارات ذات الخلفية السوداء. */
  background: #f8fafc;
  border-radius: 50%;
  box-shadow: 0 0 0 2px #e2e8f0;
  -webkit-transition: box-shadow .18s ease;
  transition: box-shadow .18s ease;
}

.academic-colleges-page .ac-card__link:hover .ac-card__media {
  box-shadow: 0 0 0 2px #c9a227;
}

.academic-colleges-page .ac-card__img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  -o-object-fit: contain;
  object-fit: contain;
}

.academic-colleges-page .ac-card__name {
  display: block;
  font-family: 'Droid Arabic Kufi', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.9;
  color: #0f3b6b;
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ---- 5.5 التذييل ---- */
.academic-colleges-page .ac-foot {
  position: static;
  margin-top: 28px;
  padding: 16px 12px;
  text-align: center;
  background: #0f3b6b;
  border-top: 3px solid #c9a227;
  border-radius: 12px;
  color: #ffffff;
}

.academic-colleges-page .ac-foot a,
.academic-colleges-page .ac-foot #programmer {
  color: #ffffff;
  text-decoration: none;
  font-size: 13px;
}

.academic-colleges-page .ac-foot a:hover { text-decoration: underline; }

/* ---- 5.6 الاستجابة ---- */
@media only screen and (max-width: 991px) {
  .academic-colleges-page .ac-hero__badge {
    -ms-flex: 1 1 100%;
    flex: 1 1 100%;
    padding-right: 0;
    padding-top: 16px;
    border-right: 0;
    border-top: 1px dashed #e2e8f0;
    text-align: center;
  }
}

@media only screen and (max-width: 767px) {
  .academic-colleges-page .ac-wrap { padding: 16px 12px 32px; }
  .academic-colleges-page .ac-hero { padding: 18px 16px; }
  .academic-colleges-page .ac-search { padding: 12px 14px; }
  .academic-colleges-page #searchLog { right: 14px; left: 14px; }
  .academic-colleges-page .ac-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .academic-colleges-page .ac-card__media { width: 86px; height: 86px; margin-bottom: 11px; padding: 8px; }
  .academic-colleges-page .ac-card__name { font-size: 13px; }
}

@media only screen and (max-width: 480px) {
  .academic-colleges-page .ac-hero__grid {
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    text-align: center;
  }
  .academic-colleges-page .ac-hero__id { -ms-flex: 1 1 100%; flex: 1 1 100%; text-align: center; }
  .academic-colleges-page .ac-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media only screen and (max-width: 360px) {
  .academic-colleges-page .ac-card__link { padding: 15px 8px 13px; }
  .academic-colleges-page .ac-card__media { width: 72px; height: 72px; }
  .academic-colleges-page .ac-card__name { font-size: 12px; line-height: 1.8; }
  .academic-colleges-page #searchLog table.table img { width: 38px; height: 38px; }
}


/* ==========================================================================
   6) الطباعة — تكميل لقواعد الطباعة الموجودة أصلاً في profile.php
   ========================================================================== */
@media print {
  .academic-profile-page .ap-card,
  .academic-profile-page .tabs > div,
  .academic-profile-page .pord {
    box-shadow: none;
    border-color: #999;
  }
  .academic-profile-page .tabbed > label { display: none; }
  .academic-profile-page .ap-links,
  .academic-profile-page .ap-visits { -webkit-box-shadow: none; box-shadow: none; }
  .academic-profile-page .pdf { height: 500px; min-height: 0; }
  .academic-directory-page .ad-card__link,
  .academic-directory-page .ad-hero,
  .academic-directory-page .ad-toolbar { box-shadow: none; }
  .academic-directory-page .ad-toolbar,
  .academic-directory-page .ad-pagination,
  .academic-directory-page #header { display: none; }
}
