/* /contact/ — "كلّمنا" (page-contact.php) */
.ct-sec { padding-top: 0; }
.ct-sec .wrap { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(18px, 3vw, 32px); align-items: start; }
.ct, .ct__done { grid-column: 1; padding: clamp(20px, 3.4vw, 36px); border-radius: 28px; border: 1px solid var(--line-2); background: var(--glass); backdrop-filter: blur(14px); }
.ct__side { grid-column: 2; grid-row: 1; position: sticky; top: 110px; }
.ct__side .why__c { margin: 0; }
.ct__side-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

.ct__types { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.ct__type { position: relative; cursor: pointer; }
.ct__type input { position: absolute; opacity: 0; pointer-events: none; }
.ct__type span { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px 8px; border-radius: 18px; text-align: center; font-weight: 600; font-size: 14px;
	border: 1px solid var(--line); background: rgba(7, 20, 26, .55); color: var(--gray-2); transition: border-color .2s, background .2s, color .2s, transform .2s var(--ease); }
.ct__type i { font-style: normal; font-size: 26px; line-height: 1; }
.ct__type:hover span { border-color: rgba(61, 216, 255, .35); transform: translateY(-2px); }
.ct__type input:checked + span { border-color: var(--cyan); background: rgba(0, 229, 255, .1); color: var(--white); box-shadow: 0 0 0 3px rgba(0, 229, 255, .12); }
.ct__type input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.ct__hint { margin: 14px 2px 20px; color: var(--cyan-l); font-size: 15px; }

.ct__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ct__f { display: flex; flex-direction: column; gap: 7px; margin-bottom: 14px; font-size: 14px; font-weight: 600; color: var(--gray-2); }
.ct__f[hidden] { display: none; }
.ct__f small { font-weight: 400; color: var(--gray); }
.ct__f input, .ct__f textarea { width: 100%; padding: 13px 15px; border-radius: 14px; border: 1px solid var(--line); background: rgba(7, 20, 26, .7); color: var(--white);
	font: 500 16px var(--f-body); transition: border-color .2s, box-shadow .2s; }
.ct__f textarea { resize: vertical; min-height: 140px; line-height: 1.8; }
.ct__f input:focus, .ct__f textarea:focus { outline: 0; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(0, 229, 255, .15); }
.ct__f input::placeholder, .ct__f textarea::placeholder { color: rgba(140, 151, 166, .7); }

.ct__foot { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 4px; }
.ct__att span { display: inline-flex; align-items: center; gap: 6px; padding: 12px 16px; border-radius: 14px; border: 1px dashed rgba(61, 216, 255, .35); color: var(--gray-2); cursor: pointer; font-size: 14px; }
.ct__att span:hover { border-color: var(--cyan); color: var(--white); }
.ct__att small { color: var(--gray); }
.ct[hidden], .ct__done[hidden], .ct__thumb[hidden] { display: none; }
.ct__thumb { width: 52px; height: 52px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line-2); }
.ct__go { margin-inline-start: auto; }
.ct__hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.ct__msg { min-height: 1.4em; margin: 12px 2px 0; color: var(--gray-2); font-size: 14px; }
.ct__msg.is-err { color: #FF8A8A; }

.ct__done { text-align: center; }
.ct__done .why__ic { margin-inline: auto; }
.ct__done p { color: var(--gray-2); }
.ct__ref { font: 600 14px var(--f-num); color: var(--cyan-l); }

@media (max-width: 900px) {
	.ct-sec .wrap { grid-template-columns: minmax(0, 1fr); }
	.ct__side { grid-column: 1; grid-row: auto; position: static; }
}
@media (max-width: 560px) {
	.ct__types { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.ct__row { grid-template-columns: minmax(0, 1fr); gap: 0; }
	.ct__go { width: 100%; margin: 0; }
}

/* ---------- "محادثاتك" ---------- */
.ct__side { display: flex; flex-direction: column; gap: 14px; }
.ct__threads[hidden] { display: none; }
.ct__tl { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ct__tl a { position: relative; display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--line); background: rgba(7, 20, 26, .55); color: var(--white); text-decoration: none; transition: border-color .2s; }
.ct__tl a:hover { border-color: var(--cyan); }
.ct__tl b { font-size: 14px; }
.ct__tl small { color: var(--gray); font-size: 12px; }
.ct__new { position: absolute; inset-inline-end: 10px; top: 10px; padding: 2px 8px; border-radius: 999px; background: var(--cyan); color: #021015; font-size: 11px; font-weight: 700; }
.ct__notice { grid-column: 1; margin: 0; padding: 12px 16px; border-radius: 14px; border: 1px solid rgba(255, 178, 74, .4); background: rgba(255, 178, 74, .08); color: #FFD08A; }

/* ---------- the chat thread (?c=) ---------- */
.ct-sec--chat { padding-top: clamp(96px, 11vw, 130px); }
.ct-sec--chat .wrap { display: block; max-width: 760px; }
.ctc { display: flex; flex-direction: column; height: min(78svh, 760px); border-radius: 28px; border: 1px solid var(--line-2); background: var(--glass); backdrop-filter: blur(14px); overflow: hidden; }
.ctc__hd { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); background: rgba(7, 20, 26, .6); }
.ctc__back { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; color: var(--white); text-decoration: none; font-size: 20px; border: 1px solid var(--line); }
.ctc__back:hover { border-color: var(--cyan); }
.ctc__av img { display: block; width: 40px; height: 40px; border-radius: 12px; }
.ctc__who { display: flex; flex-direction: column; min-width: 0; }
.ctc__who b { font-size: 16px; }
.ctc__who small { color: var(--gray-2); font-size: 13px; }
.ctc__ref { margin-inline-start: auto; font: 600 11px var(--f-num); color: var(--gray); white-space: nowrap; }
.ctc__log { flex: 1; overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; gap: 10px; padding: 18px; }
.ctc__load { margin: auto; color: var(--gray); }
.ctc__b { max-width: 82%; padding: 10px 14px 6px; border-radius: 18px; line-height: 1.75; font-size: 15px; animation: ctcIn .25s var(--ease); }
.ctc__b p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.ctc__b time { display: block; margin-top: 4px; font-size: 11px; opacity: .7; }
.ctc__b img { display: block; max-width: 100%; max-height: 300px; border-radius: 12px; margin-bottom: 6px; }
.ctc__b--me { align-self: flex-start; background: var(--cyan); color: #021015; border-end-start-radius: 6px; }
.ctc__b--them { align-self: flex-end; background: rgba(13, 42, 51, .9); border: 1px solid var(--line-2); color: var(--white); border-end-end-radius: 6px; }
@keyframes ctcIn { from { opacity: 0; transform: translateY(6px); } }
.ctc__wait { margin: 0; padding: 8px 18px; font-size: 13px; color: var(--cyan-l); border-top: 1px solid var(--line); }
.ctc__wait[hidden] { display: none; }
.ctc__box { display: flex; align-items: flex-end; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: rgba(7, 20, 26, .6); }
.ctc__box textarea { flex: 1; resize: none; min-height: 46px; max-height: 160px; padding: 11px 14px; border-radius: 16px; border: 1px solid var(--line); background: rgba(7, 20, 26, .8); color: var(--white); font: 500 16px var(--f-body); line-height: 1.5; }
.ctc__box textarea:focus { outline: 0; border-color: var(--cyan); }
.ctc__att span { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; border: 1px dashed rgba(61, 216, 255, .35); cursor: pointer; font-size: 19px; }
.ctc__att span:hover { border-color: var(--cyan); }
.ctc__thumb { width: 46px; height: 46px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line-2); }
.ctc__thumb[hidden] { display: none; }
.ctc__send { min-height: 46px; padding: 0 20px; border-radius: 14px; }
.ctc + .ct__msg, .ctc .ct__msg { margin: 0; padding: 0 18px 8px; }
@media (max-width: 560px) {
	.ct-sec--chat .wrap { padding-inline: 10px; }
	.ctc { height: calc(100svh - 120px); border-radius: 22px; }
	.ctc__ref { display: none; }
	.ctc__b { max-width: 90%; }
}