/* ==========================================================================
   FCAI Services - Main application shell stylesheet
   Quality Assurance Management System - Cairo University
   ========================================================================== */

@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/plus-jakarta-sans-400.woff') format('woff');
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/plus-jakarta-sans-500.woff') format('woff');
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/plus-jakarta-sans-600.woff') format('woff');
}
@font-face {
  font-family: 'EB Garamond';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/eb-garamond-400.woff') format('woff');
}
@font-face {
  font-family: 'EB Garamond';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/eb-garamond-500.woff') format('woff');
}
@font-face {
  font-family: 'EB Garamond';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/eb-garamond-400-italic.woff') format('woff');
}
/* Arabic UI font, self-hosted like the two above - Arabic Unicode-range
   subset only (~14-31KB each), used site-wide once dir="rtl" is active
   (see rtl.css) and as the first choice for .text-ar/.text-ar-inline
   regardless of page language. */
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/cairo-400.woff2') format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFC, U+200C-200E;
}
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/cairo-600.woff2') format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFC, U+200C-200E;
}
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/cairo-700.woff2') format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFC, U+200C-200E;
}

:root {
  /* Cairo University brand foundation */
  --cu-parchment: #EFEACC;
  --cu-parchment-line: #E0D9AE;
  --cu-burgundy: #8A0000;
  --cu-burgundy-tint: #FBEAEA;
  --cu-navy: #313168;
  --cu-navy-tint: #E9E9F4;
  --cu-sky: #9FDCEF;
  --cu-deep: #1A1A40;

  /* Application semantic tokens */
  --accent: #8A0000;
  --accent-focus: rgba(139, 0, 0, 0.2);
  --sidebar: #313168;
  --sidebar-active-bg: rgba(139, 0, 0, 0.15);
  --bg: #F3F4F6;
  --white: #FFFFFF;
  --border: #E5E7EB;
  --text: #111827;
  --text-muted: #6B7280;

  /* Status colors */
  --success-bg: #DCFCE7;
  --success-text: #166534;
  --warning-bg: #FEF3C7;
  --warning-text: #92400E;
  --danger-bg: #FEE2E2;
  --danger-text: #991B1B;
  --info-bg: #DBEAFE;
  --info-text: #1E40AF;
  --danger: #DC2626;
  --success: #16A34A;

  /* Dashboard service-category tints (Quality Assurance / Administrative /
     Financial / Academic tiles) - quality reuses the navy tint already used
     for link-type services elsewhere on the dashboard for consistency. */
  --tint-admin-bg: #DCFCE7;
  --tint-admin-fg: #166534;
  --tint-finance-bg: #FEF3C7;
  --tint-finance-fg: #92400E;
  --tint-academic-bg: #EDE9FE;
  --tint-academic-fg: #5B21B6;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

h1, h2, h3, h4 {
  margin: 0 0 8px 0;
  font-weight: 600;
  line-height: 1.3;
}

h1 { font-size: 24px; }
h2 { font-size: 20px; }
h3 { font-size: 18px; }

p { margin: 0 0 12px 0; }

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

.eyebrow {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text-muted);
}

.small, .text-muted {
  font-size: 12px;
  color: var(--text-muted);
}

.text-ar {
  display: block;
  direction: rtl;
  text-align: right;
  font-family: 'Cairo', 'EB Garamond', 'Amiri', 'Traditional Arabic', serif;
  font-size: 1.08em;
  color: var(--text-muted);
}

/* .text-ar dims to text-muted by default (right for a small inline label),
   but a page heading needs the same bold weight/color an English h1 gets -
   without this it reads as a faint subtitle instead of a title. */
h1.text-ar, h2.text-ar, h3.text-ar {
  color: var(--text);
  font-weight: 700;
}

/* Same bilingual convention as .text-ar, but sits inline beside its
   English counterpart instead of stacking below it. */
.text-ar-inline {
  display: inline-block;
  direction: rtl;
  text-align: right;
  font-family: 'Cairo', 'EB Garamond', 'Amiri', 'Traditional Arabic', serif;
  font-size: 1.08em;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------
   App shell layout
   -------------------------------------------------------------------- */

.app-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 240px;
  flex-shrink: 0;
  background: var(--sidebar);
  color: #fff;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 20;
  transition: transform 0.2s ease;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 20px;
}

.sidebar-brand img {
  width: 32px;
  height: 32px;
  background: #fff;
  border-radius: 8px;
  padding: 2px;
  object-fit: contain;
}

.sidebar-brand span {
  font-weight: 700;
  font-size: 16px;
  color: #fff;
}

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 500;
  border-left: 3px solid transparent;
  transition: background 0.2s ease;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.06);
  text-decoration: none;
  color: #fff;
}

.nav-link.active {
  background: var(--sidebar-active-bg);
  color: #fff;
  border-left-color: var(--accent);
}

.sidebar-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 0;
}

.main {
  flex: 1;
  margin-left: 240px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  height: 60px;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.sidebar-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 10px;
  cursor: pointer;
  font-size: 14px;
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

/* --------------------------------------------------------------------
   Language switcher (topbar + login page)
   -------------------------------------------------------------------- */

.lang-switch {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 2px;
  border-radius: 999px;
  background: #F3F4F6;
}
.lang-switch-link {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}
.lang-switch-link:hover { text-decoration: none; color: var(--text); }
.lang-switch-link.active {
  background: var(--cu-navy, var(--accent));
  color: #fff;
}
.auth-shell .lang-switch {
  position: absolute;
  top: 20px;
  inset-inline-end: 20px;
  z-index: 5;
  background: rgba(255, 255, 255, 0.14);
}
.auth-shell .lang-switch-link { color: rgba(255, 255, 255, 0.8); }
.auth-shell .lang-switch-link.active { background: #fff; color: var(--cu-navy, #313168); }

.topbar-user .role-tag {
  text-transform: capitalize;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------
   Notification bell + dropdown
   -------------------------------------------------------------------- */

.notif-bell {
  position: relative;
}

.notif-bell-btn {
  position: relative;
  background: none;
  border: none;
  font-size: 17px;
  line-height: 1;
  padding: 4px;
  cursor: pointer;
  color: var(--text-muted);
}

.notif-badge {
  position: absolute;
  top: -3px;
  right: -4px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 999px;
  padding: 1px 5px;
  line-height: 1.4;
}

.notif-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 320px;
  max-height: 400px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  z-index: 20;
  text-align: left;
}

.notif-bell.open .notif-dropdown {
  display: block;
}

.notif-dropdown-header {
  padding: 12px 16px;
  font-weight: 600;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
}

.notif-dropdown-empty {
  padding: 16px;
  font-size: 13px;
  color: var(--text-muted);
}

.notif-dropdown-item {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
}

.notif-dropdown-item:last-of-type {
  border-bottom: none;
}

.notif-dropdown-item.unread {
  background: var(--info-bg, #DBEAFE);
}

.notif-dropdown-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.notif-dropdown-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.notif-dropdown-viewall {
  display: block;
  text-align: center;
  padding: 10px 16px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.notif-banner {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  background: #fff;
  border: 1px solid var(--border);
  border-left: 6px solid var(--accent);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 28px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
}

.notif-banner-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--info-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.notif-banner-body {
  flex: 1;
  min-width: 0;
}

.notif-banner-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.notif-banner-new {
  font-size: 10px;
  animation: notif-banner-pulse 1.8s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .notif-banner-new { animation: none; }
}

@keyframes notif-banner-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

.notif-banner-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.notif-banner-message {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
}

.content {
  padding: 24px;
  flex: 1;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

@media (max-width: 1024px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .main {
    margin-left: 0;
  }
  .sidebar-toggle {
    display: inline-flex;
    align-items: center;
  }
}

/* --------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  border-radius: 6px;
  padding: 9px 16px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.14s, transform 0.08s;
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #700000; text-decoration: none; }

.btn-secondary { background: #fff; color: var(--text); border-color: var(--border); }
.btn-secondary:hover { background: #F9FAFB; text-decoration: none; }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #B91C1C; text-decoration: none; }

.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #15803D; text-decoration: none; }

.btn-sm { padding: 5px 10px; font-size: 12px; }

.btn:disabled, .btn.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-focus);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 13px;
}
.icon-btn:hover { background: #F9FAFB; color: var(--text); }
.icon-btn.icon-btn-danger:hover { background: var(--danger-bg); color: var(--danger-text); border-color: var(--danger-bg); }

/* --------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------- */

.form-group { margin-bottom: 16px; }

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 6px;
}

.req { color: var(--cu-burgundy); margin-left: 2px; }

.form-control {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 12px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  color: var(--text);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-focus);
}

.form-control:disabled {
  background: #F3F4F6;
  color: var(--text-muted);
  cursor: not-allowed;
}

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

.form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

.field-error {
  font-size: 12px;
  color: var(--danger-text);
  margin-top: 6px;
}

.form-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.form-row .form-group { flex: 1; min-width: 200px; }

.form-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

/* --------------------------------------------------------------------
   Cards
   -------------------------------------------------------------------- */

.card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  padding: 20px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.stat-card .stat-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.stat-card .stat-value {
  font-size: 28px;
  font-weight: 700;
}

/* --------------------------------------------------------------------
   Dashboard hero
   -------------------------------------------------------------------- */

.hero {
  background: linear-gradient(180deg, var(--cu-parchment) 0%, #F6F3E1 100%);
  border: 1px solid var(--cu-parchment-line);
  border-top: 3px solid var(--cu-burgundy);
  border-radius: 10px;
  padding: 26px 30px;
  margin-bottom: 26px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.hero-eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #7A6A2E;
  margin-bottom: 10px;
}
.hero-greeting {
  font-family: 'EB Garamond', 'Amiri', 'Traditional Arabic', serif;
  font-style: italic;
  font-size: 32px;
  color: var(--cu-deep);
}
.hero-date {
  font-size: 12px;
  color: #7A6A2E;
  text-align: right;
  white-space: nowrap;
}
.hero-date strong { display: block; font-size: 15px; color: var(--cu-deep); font-weight: 600; }

@media (max-width: 640px) {
  .hero { flex-direction: column; align-items: flex-start; }
  .hero-date { text-align: left; }
}

/* --------------------------------------------------------------------
   Dashboard search + category tiles + recent-requests/announcements split
   -------------------------------------------------------------------- */

.dash-search { position: relative; max-width: 420px; margin-bottom: 22px; }
.dash-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: var(--text-muted); }
.dash-search input {
  width: 100%; border: 1px solid var(--border); border-radius: 10px; background: #fff;
  padding: 11px 14px 11px 40px; font-size: 13.5px; font-family: inherit;
}
.dash-search input:focus { outline: none; border-color: var(--cu-navy); box-shadow: 0 0 0 3px var(--accent-focus); }

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}
.category-tile {
  background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 18px;
  display: flex; flex-direction: column; gap: 8px; color: inherit; text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}
.category-tile:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.08); border-color: var(--cu-sky); text-decoration: none; }
.category-tile h3 { font-size: 14.5px; font-weight: 700; margin: 0; }
.category-tile p { font-size: 12px; color: var(--text-muted); margin: 0; }

.category-badge {
  width: 42px; height: 42px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.category-badge svg { width: 20px; height: 20px; }
.category-badge.tint-quality { background: var(--cu-navy-tint); color: var(--cu-navy); }
.category-badge.tint-admin { background: var(--tint-admin-bg); color: var(--tint-admin-fg); }
.category-badge.tint-finance { background: var(--tint-finance-bg); color: var(--tint-finance-fg); }
.category-badge.tint-academic { background: var(--tint-academic-bg); color: var(--tint-academic-fg); }

.category-section-heading {
  display: flex; align-items: center; gap: 10px;
  font-size: 16px; font-weight: 700; margin: 30px 0 14px;
  scroll-margin-top: 76px;
}
.category-section-heading:first-of-type { margin-top: 0; }
.category-section-heading .category-badge { width: 30px; height: 30px; }
.category-section-heading .category-badge svg { width: 15px; height: 15px; }

.dash-split {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 18px;
  margin-bottom: 32px;
  align-items: start;
}
.dash-panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.dash-panel-head h2 { font-size: 14.5px; font-weight: 700; margin: 0; }
.dash-panel-link { font-size: 12px; font-weight: 600; white-space: nowrap; }
.dash-panel .data-table { margin-top: 10px; }
.dash-panel .empty-state { padding: 24px 12px; }

.dash-panel-announce { background: var(--cu-parchment); border-color: var(--cu-parchment-line); }
.announce-list { display: flex; flex-direction: column; margin-top: 10px; }
.announce-item { display: flex; gap: 12px; padding: 10px 2px; border-bottom: 1px solid var(--cu-parchment-line); }
.announce-item:last-child { border-bottom: none; }
.announce-date { font-size: 11px; font-weight: 700; color: var(--cu-burgundy); white-space: nowrap; padding-top: 1px; }
.announce-title { font-size: 12.5px; font-weight: 600; color: var(--text); }

@media (max-width: 860px) {
  .dash-split { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------
   Dashboard feature strip
   -------------------------------------------------------------------- */

.feature-strip {
  margin-top: 30px;
  background: #fff; border: 1px solid var(--border); border-radius: 12px;
  display: flex;
}
.feature-item { flex: 1; display: flex; align-items: center; gap: 12px; padding: 18px 22px; }
.feature-item + .feature-item { border-left: 1px solid var(--border); }
.feature-item svg { width: 22px; height: 22px; color: var(--cu-navy); flex-shrink: 0; }
.feature-item h4 { font-size: 13px; font-weight: 700; margin: 0; }
.feature-item p { font-size: 11.5px; color: var(--text-muted); margin: 2px 0 0; }

@media (max-width: 720px) {
  .feature-strip { flex-direction: column; }
  .feature-item + .feature-item { border-left: none; border-top: 1px solid var(--border); }
}

/* --------------------------------------------------------------------
   Service catalog (dashboard)
   -------------------------------------------------------------------- */

.section-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.section-label h2 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin: 0;
}
.section-legend { display: flex; gap: 16px; font-size: 11.5px; color: var(--text-muted); }
.legend-dot { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }
.legend-dot-request { background: var(--cu-burgundy); }
.legend-dot-link { background: var(--cu-navy); }

.service-group-heading {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 12px;
}
.service-group-heading:first-of-type { margin-top: 0; }

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

.service-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 18px 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.service-card::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
}
.service-card.track-request::before { background: var(--cu-burgundy); }
.service-card.track-link::before { background: var(--cu-navy); }

.service-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  text-decoration: none;
}

.service-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.service-icon {
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.track-request .service-icon { background: var(--cu-burgundy-tint); color: var(--cu-burgundy); }
.track-link .service-icon { background: var(--cu-navy-tint); color: var(--cu-navy); }
.service-icon svg { width: 18px; height: 18px; }

.service-kind {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.track-request .service-kind { background: var(--cu-burgundy-tint); color: var(--cu-burgundy); }
.track-link .service-kind { background: var(--cu-navy-tint); color: var(--cu-navy); }

.service-card h4 { margin: 0; font-size: 15.5px; font-weight: 600; }
.service-card p { color: var(--text-muted); font-size: 12.5px; margin-bottom: 0; flex: 1; }
.service-card .text-ar { font-size: 1.3em; }

.service-meta {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 5px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.track-request .service-meta { color: var(--cu-burgundy); }
.track-link .service-meta { color: var(--cu-navy); }

@media (prefers-reduced-motion: reduce) {
  .service-card { transition: none; }
}

/* --------------------------------------------------------------------
   Badges
   -------------------------------------------------------------------- */

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.badge-green { background: var(--success-bg); color: var(--success-text); }
.badge-amber { background: var(--warning-bg); color: var(--warning-text); }
.badge-red { background: var(--danger-bg); color: var(--danger-text); }
.badge-blue { background: var(--info-bg); color: var(--info-text); }
.badge-grey { background: #E5E7EB; color: #374151; }

/* --------------------------------------------------------------------
   Alerts
   -------------------------------------------------------------------- */

.alert {
  padding: 12px 16px;
  border-radius: 6px;
  font-size: 13px;
  margin-bottom: 16px;
}
.alert-success { background: var(--success-bg); color: var(--success-text); }
.alert-error { background: var(--danger-bg); color: var(--danger-text); }
.alert-info { background: var(--info-bg); color: var(--info-text); }
.alert-warning { background: var(--warning-bg); color: var(--warning-text); }

/* --------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------- */

.table-wrap { overflow-x: auto; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: #fff;
}
.data-table th {
  background: #F9FAFB;
  color: var(--text-muted);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.05em;
  text-align: left;
  padding: 12px;
  border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.data-table tbody tr:nth-child(odd) { background: #FAFAFB; }
.data-table th a {
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.data-table th a:hover { color: var(--text); text-decoration: underline; }
.data-table tbody tr:hover { background: #F1F5F9; }

.table-actions {
  display: flex;
  gap: 6px;
}

/* --------------------------------------------------------------------
   Progress bars
   -------------------------------------------------------------------- */

.progress-bar-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
}
.progress-bar-fill.complete { background: var(--success); }
.progress-bar-fill.warning { background: var(--warning-text); }

/* --------------------------------------------------------------------
   Misc / utility
   -------------------------------------------------------------------- */

.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-muted);
}

.filter-bar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  align-items: flex-end;
}
.filter-bar .form-group { margin-bottom: 0; }

@media (max-width: 640px) {
  .content { padding: 16px; }
  .filter-bar { flex-direction: column; align-items: stretch; }
}

/* --------------------------------------------------------------------
   Motion
   -------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .btn, .form-control, .nav-link, .sidebar {
    transition: none;
  }
}
