/* OraClass UI — brand: dark blue/graphite + orange, Tajawal, RTL-first. */
@font-face { font-family: Tajawal; src: url(../fonts/Tajawal/Tajawal-Regular.ttf) format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: Tajawal; src: url(../fonts/Tajawal/Tajawal-Medium.ttf) format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: Tajawal; src: url(../fonts/Tajawal/Tajawal-Bold.ttf) format("truetype"); font-weight: 700; font-display: swap; }

:root {
  --brand: #F49156; --brand-2: #EC675A; --bg: #0F1419; --bg-2: #1A2027; --bg-3: #25313B;
  --text: #E5E7EB; --muted: #9CA3AF; --line: rgba(255,255,255,.09); --radius: 14px;
}
html { font-size: 15px; }
body { font-family: Tajawal, system-ui, sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; }
a { color: var(--brand); } a:hover { color: var(--brand-2); }
h1,h2,h3,h4,h5 { font-weight: 700; color: #fff; }
.text-muted, .form-text, small.muted { color: var(--muted) !important; }
.skip { position: absolute; top: 4px; right: 4px; z-index: 2000; background: #fff; color: #000; padding: 6px 10px; }


/* buttons */
.btn-brand { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; border: 0; }
.btn-brand:hover, .btn-brand:focus { color: #fff; filter: brightness(1.08); }
.btn-outline-light { border-color: var(--line); }
.btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }

/* surfaces */
.card, .panel { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); }
.panel { padding: 1.25rem; margin-bottom: 1rem; }
.card-img-top { border-radius: var(--radius) var(--radius) 0 0; height: 180px; object-fit: cover; }
.hero { padding: 4.5rem 0 3rem; background: radial-gradient(1200px 400px at 80% -10%, rgba(244,145,86,.18), transparent), var(--bg); }
.stat { text-align: center; } .stat b { display: block; font-size: 2rem; color: var(--brand); }
.section { padding: 2.5rem 0; }

/* forms & tables */
.form-control, .form-select { background: var(--bg-3); border-color: var(--line); color: #fff; }
.form-control:focus, .form-select:focus { background: var(--bg-3); color: #fff; border-color: var(--brand); box-shadow: none; }
.form-control::placeholder { color: #6b7280; }
.form-label { color: var(--text); font-weight: 500; }
.table { color: var(--text); --bs-table-bg: transparent; } .table td, .table th { border-color: var(--line); vertical-align: middle; }
.table thead th { color: var(--muted); font-weight: 500; white-space: nowrap; }
.table-hover tbody tr:hover { color: #fff; background: rgba(255,255,255,.03); }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
.code { font-family: ui-monospace, Consolas, monospace; direction: ltr; unicode-bidi: isolate; letter-spacing: .05em; }
.alert { border-radius: 10px; }
.pagination .page-link { background: var(--bg-2); border-color: var(--line); color: var(--text); }
.pagination .active .page-link { background: var(--brand); border-color: var(--brand); }
.stars { color: #FFC107; letter-spacing: 1px; }
.badge.bg-warning, .badge.bg-info { color: #111; }
.dropdown-menu { background: var(--bg-2); } .dropdown-item { color: var(--text); }

/* admin / account shell */
.shell { display: flex; flex: 1; min-height: calc(100vh - 60px); }
.sidenav { width: 240px; flex-shrink: 0; background: var(--bg-2); border-left: 1px solid var(--line); padding: 1rem .5rem; }
.sidenav a { display: block; padding: .55rem .8rem; border-radius: 8px; color: var(--text); text-decoration: none; margin-bottom: 2px; }
.sidenav a:hover { background: var(--bg-3); } .sidenav a.active { background: rgba(244,145,86,.15); color: var(--brand); font-weight: 700; }
.content { flex: 1; padding: 1.5rem 2rem; min-width: 0; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.page-head h1 { font-size: 1.5rem; margin: 0; }
.kpi { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.25rem; }
.kpi span { color: var(--muted); font-size: .9rem; } .kpi b { display: block; font-size: 1.5rem; color: #fff; }

/* certificate print */
.cert { width: 297mm; height: 210mm; margin: 1rem auto; background: #fff center/cover no-repeat; color: #1a2027; position: relative; box-shadow: 0 0 20px rgba(0,0,0,.5); }
.cert .inner { position: absolute; inset: 22mm 25mm; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.cert h1 { color: #1A2027; font-size: 28pt; } .cert .name { font-size: 30pt; font-weight: 700; color: #C8552B; margin: 6mm 0; }
.cert .qr { position: absolute; left: 0; bottom: 0; text-align: center; font-size: 8pt; }
.cert .signers { display: flex; gap: 25mm; margin-top: 10mm; }
.watermark { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 60pt; color: rgba(200,0,0,.18); transform: rotate(-20deg); pointer-events: none; }

.footer { background: var(--bg-2); border-top: 1px solid var(--line); padding: 1.5rem 0; margin-top: 2rem; }
.footer a { color: var(--muted); }

@media (max-width: 991px) {
  .shell { flex-direction: column; } .sidenav { width: 100%; display: flex; overflow-x: auto; gap: 4px; padding: .5rem; border-left: 0; border-bottom: 1px solid var(--line); }
  .sidenav a { white-space: nowrap; } .content { padding: 1rem; }
}
@media print {
  body { background: #fff; } .oc-nav, .footer, .sidenav, .no-print, .alert { display: none !important; }
  .cert { margin: 0; box-shadow: none; } @page { size: A4 landscape; margin: 0; }
}
