/*
 * Musaid marketing site. Hand-written CSS, no build step: the page is four
 * sections and must load instantly on a Kuwaiti phone. Colours and the Tajawal
 * face are the same tokens the dashboards use (packages/web-kit's preset), so
 * a visitor who signs in does not land somewhere that looks like a different
 * product.
 *
 * Logical properties (margin-inline, text-align: start) throughout — the page
 * flips between RTL Arabic and LTR English with one `dir` change and no
 * mirrored stylesheet.
 */
:root {
  --brand-500: #2f7de1;
  --brand-600: #1f63c0;
  --brand-700: #1a4f99;
  --brand-900: #12305c;
  --brand-50: #eef6ff;
  --ink: #0f172a;
  --ink-muted: #475569;
  --ink-subtle: #64748b;
  --surface: #ffffff;
  --surface-sunken: #f6f8fb;
  --surface-border: #e2e8f0;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Tajawal', system-ui, sans-serif;
  color: var(--ink);
  background: var(--surface);
  line-height: 1.7;
}

.wrap {
  width: min(1100px, 100% - 2.5rem);
  margin-inline: auto;
}

h1,
h2,
h3 {
  line-height: 1.3;
  margin: 0;
}

/* ── Header ───────────────────────────────────────────────────────────────── */
.top {
  border-block-end: 1px solid var(--surface-border);
  background: var(--surface);
  position: sticky;
  top: 0;
  z-index: 10;
}

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
}

.bar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 800;
  font-size: 1.25rem;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 0.7rem;
  background: var(--brand-700);
  color: #fff;
  font-size: 1.1rem;
}

.lang,
.signin {
  border: 1px solid var(--surface-border);
  background: var(--surface);
  color: var(--ink-muted);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.45rem 0.9rem;
  border-radius: 0.6rem;
  cursor: pointer;
  text-decoration: none;
}

.signin {
  background: var(--brand-700);
  border-color: var(--brand-700);
  color: #fff;
  font-weight: 700;
}

.lang:hover,
.signin:hover {
  filter: brightness(1.08);
}

/* ── Hero ─────────────────────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(160deg, var(--brand-50), var(--surface) 70%);
  padding-block: clamp(3rem, 9vw, 6rem);
  text-align: center;
}

.pill {
  display: inline-block;
  margin: 0 0 1rem;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  background: var(--brand-100, #d9eaff);
  color: var(--brand-900);
  font-size: 0.85rem;
  font-weight: 700;
}

.hero h1 {
  font-size: clamp(1.9rem, 5.5vw, 3.2rem);
  font-weight: 800;
  color: var(--brand-900);
  max-width: 22ch;
  margin-inline: auto;
}

.lead {
  color: var(--ink-muted);
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  max-width: 60ch;
  margin: 1rem auto 0;
}

.cta {
  display: inline-block;
  margin-top: 1.8rem;
  padding: 0.8rem 1.8rem;
  border-radius: 0.8rem;
  background: var(--brand-700);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.cta:hover {
  background: var(--brand-600);
}

/* ── Sections ─────────────────────────────────────────────────────────────── */
section {
  padding-block: clamp(2.5rem, 7vw, 4.5rem);
}

section h2 {
  font-size: clamp(1.4rem, 3.6vw, 2rem);
  font-weight: 800;
  color: var(--brand-900);
  text-align: center;
  margin-block-end: 2rem;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

.grid article,
.card-link {
  border: 1px solid var(--surface-border);
  border-radius: 1rem;
  padding: 1.3rem;
  background: var(--surface);
}

.grid h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--brand-700);
  margin-block-end: 0.4rem;
}

.grid p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.95rem;
}

.roles {
  background: var(--surface-sunken);
}

.features ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}

.features li {
  border-inline-start: 3px solid var(--brand-500);
  padding-inline-start: 1rem;
  color: var(--ink-muted);
}

.features strong {
  display: block;
  color: var(--ink);
  font-size: 1.02rem;
  margin-block-end: 0.25rem;
}

/* ── Sign-in cards ────────────────────────────────────────────────────────── */
.signin-section {
  background: var(--surface-sunken);
}

.signin-section .lead {
  text-align: center;
  margin-block-end: 1.6rem;
}

.card-link {
  display: block;
  text-decoration: none;
  transition:
    border-color 0.15s,
    transform 0.15s;
}

.card-link:hover {
  border-color: var(--brand-500);
  transform: translateY(-2px);
}

/* A surface with no URL yet is visibly not a link, rather than a dead one. */
.card-link.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* ── Contact + footer ─────────────────────────────────────────────────────── */
.contact {
  text-align: center;
}

.contact p {
  color: var(--ink-muted);
  max-width: 60ch;
  margin-inline: auto;
}

footer {
  border-block-start: 1px solid var(--surface-border);
  padding-block: 1.5rem;
  color: var(--ink-subtle);
  font-size: 0.9rem;
  text-align: center;
}
