/* The chat with the sheikh and the notifications (student/social.js) in the navy design. Cards, rows and chips come
   from apply.css and student.css; this adds the bubbles, the offer card, the composer above the tab bar and the
   notification icons. */

/* who the student is talking to */
.card.sc-head { flex-direction: row; align-items: center; gap: 12px; padding: 12px 14px; }
.sc-av { flex: none; width: 44px; height: 44px; border-radius: 50%; overflow: hidden; background: var(--brand-soft); }
.sc-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc-head .rt { display: flex; flex-direction: column; gap: 1px; line-height: 1.35; }
.sc-head b { font-size: var(--text-input); font-weight: 700; }
.sc-head small { font-size: 13.5px; font-weight: 500; color: var(--ink-3); }

/* the conversation: the sheikh on the start side (white), the student on the end side (soft navy) */
.sc-thread { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.sc-day { align-self: center; margin-block: 8px 4px; padding: 4px 12px; border-radius: var(--radius-pill); background: var(--fill-2); color: var(--ink-2); font-size: 12.5px; font-weight: 700; line-height: 1.3; }
.sc-msg { max-width: 84%; padding: 10px 14px 8px; border-radius: 18px; display: flex; flex-direction: column; gap: 4px; font-size: 15.5px; line-height: 1.6; }
.sc-msg p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.sc-msg time { font-size: 11.5px; font-weight: 500; line-height: 1; color: var(--ink-3); }
.sc-them { align-self: flex-start; background: var(--surface); box-shadow: var(--shadow); border-start-start-radius: 6px; }
.sc-me { align-self: flex-end; background: var(--brand-soft); color: var(--ink); border-start-end-radius: 6px; }
.sc-me time { align-self: flex-end; color: #5D6C96; }
.sc-typing { margin: 0; align-self: flex-start; font-size: var(--text-sm); color: var(--ink-2); }

/* the offer of a freed time: a gold band, the time, the countdown and the two answers */
.sc-sys { display: flex; margin-block: 6px 2px; }
.sc-offer { width: 100%; overflow: hidden; border-radius: 20px; background: var(--surface); box-shadow: var(--shadow); }
.sc-offer-top { display: flex; align-items: center; gap: 10px; padding: 14px 16px 12px; background: var(--gold); box-shadow: inset 0 -1px 0 var(--gold-edge); }
.sc-offer-ico { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--gold-ink); }
.sc-offer-top b { display: block; font-size: var(--text-input); font-weight: 800; line-height: 1.3; }
.sc-offer-top small { display: block; font-size: 13.5px; font-weight: 500; color: var(--gold-ink); }
.sc-offer-body { display: grid; gap: 12px; padding: 14px 16px 12px; }
.sc-offer-body > p { margin: 0; font-size: var(--text-base); line-height: 1.6; }
.sc-offer-body > time { font-size: 11.5px; font-weight: 500; color: var(--ink-3); }
.sc-left-box { display: grid; gap: 7px; }
.sc-left { margin: 0; display: flex; align-items: center; gap: 6px; font-size: var(--text-md); font-weight: 500; color: var(--amber); }
#sc-left { font-size: var(--text-base); font-weight: 800; font-variant-numeric: tabular-nums; }
.sc-bar { display: block; height: 5px; border-radius: 3px; background: var(--fill-2); overflow: hidden; }
.sc-bar i { display: block; height: 100%; border-radius: 3px; background: var(--gold-mark); transform-origin: right; transition: transform 1s linear; }   /* RTL: it runs out toward the start */
.sc-offer-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sc-offer-btns .btn { height: 52px; font-size: 15.5px; }
.btn.sc-soft { background: var(--brand-soft); box-shadow: none; color: var(--brand); }
.sc-help { margin: 0; font-size: 13.5px; font-weight: 500; line-height: 1.55; color: var(--ink-3); }
.sc-result { margin: 0; padding: 10px 12px; border-radius: var(--radius-md); background: var(--brand-soft); color: var(--brand); font-size: var(--text-md); font-weight: 700; }
.sc-result.no { background: var(--fill-2); color: var(--ink-2); }
.sc-result:focus { outline: none; }

/* the composer: a pill just above the tab bar (its 52px links and 14px padding), the send button inside it on the left
   (the page is RTL; the text, either way, keeps clear of it) */
.sc-spacer { flex: none; height: 60px; }
.sc-compose { position: fixed; z-index: 39; inset-inline: 0; bottom: calc(env(safe-area-inset-bottom, 0px) + 66px); max-width: 480px; margin: 0 auto; padding: 8px 16px 10px;
  background: linear-gradient(to bottom, rgba(242, 244, 249, 0), var(--ground) 40%); }
.sc-compose input { width: 100%; height: 56px; padding: 0 18px 0 64px; border: 0; border-radius: var(--radius-pill); background: var(--surface); box-shadow: var(--shadow-lift); transition: box-shadow 150ms ease-out; }
.sc-compose input::placeholder { color: #8E96AE; }
.sc-compose input:placeholder-shown { direction: rtl; }   /* dir=auto reads an empty field as LTR; the hint is Arabic */
.sc-compose input:focus { outline: none; box-shadow: 0 0 0 1px var(--navy-2), 0 0 0 5px var(--brand-soft); }
.sc-send { position: absolute; top: 14px; inset-inline-end: 22px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--grad); color: var(--on-accent); box-shadow: var(--shadow-navy); display: grid; place-items: center; transition: transform 150ms var(--ease); }
.sc-send:active { transform: scale(.94); }
.sc-send svg { transform: scaleX(-1); }   /* the plane points the way the text goes */

/* notifications: a card a day, the time beside each title */
.sc-group { display: flex; flex-direction: column; gap: 10px; }
.sc-group .section-title { margin: 6px 4px 0; display: flex; align-items: baseline; gap: 8px; font-size: 17px; font-weight: 800; }
.sc-group .section-title small { font-size: 13.5px; font-weight: 500; color: var(--ink-3); }
.card.sc-card { gap: 0; padding: 0; overflow: hidden; }
.sc-nrow { align-items: flex-start; padding: 14px 16px; transition: background-color 150ms ease-out; }
.sc-nrow:active { background: var(--navy-wash); }
.sc-nrow .rt { gap: 4px; }
.sc-nhead { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.sc-nrow .rt small { font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
.sc-ago { flex: none; font-size: 12.5px; font-weight: 500; color: var(--ink-3); white-space: nowrap; }
.ri.sc-t-offer, .ri.sc-t-ijaza { background: var(--gold); color: var(--gold-ink); }
.ri.sc-t-report { background: var(--live-soft); color: var(--live); }
.ri.sc-t-reminder { background: var(--fill-2); color: var(--ink-2); }
.ri.sc-t-cancel { background: var(--danger-bg); color: var(--danger); }
.sc-settings { align-self: center; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; font-size: 14.5px; }

@media (hover: hover) and (pointer: fine) {
  .sc-nrow:hover { background: var(--navy-wash); }
  .btn.sc-soft:hover { background: #DDE3F4; }
}
@media (prefers-reduced-motion: reduce) { .sc-bar i, .sc-send { transition: none; } }
