@font-face {
  font-family: "ThmanyahSans";
  font-weight: 300;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahsans-Light.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSans";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahsans-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSans";
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahsans-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSans";
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahsans-Bold.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSans";
  font-weight: 900;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahsans-Black.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSerifDisplay";
  font-weight: 300;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahserifdisplay-Light.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSerifDisplay";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahserifdisplay-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSerifDisplay";
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahserifdisplay-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSerifDisplay";
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahserifdisplay-Bold.woff2") format("woff2");
}
@font-face {
  font-family: "ThmanyahSerifDisplay";
  font-weight: 900;
  font-style: normal;
  font-display: swap;
  src: url("/assets/fonts/thmanyahserifdisplay-Black.woff2") format("woff2");
}

:root {
  --bg: #ffffff;
  --bg-alt: #f5f2fa;
  --surface: #ffffff;
  --text: #17212b;
  --muted: #66778a;
  --primary: #163a66;
  --primary-dark: #0d2745;
  --gold: #b98b4a;
  --accent: #3e9edb;
  --accent-soft: color-mix(in srgb, var(--accent) 14%, var(--surface));
  --border: rgba(23, 33, 43, 0.09);
  --shadow: 0 10px 30px -12px rgba(13, 39, 69, 0.18);
  --ease-premium: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --dur-fast: 0.2s;
  --dur-normal: 0.4s;
  --dur-slow: 0.7s;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141414;
    --bg-alt: #1c1c1c;
    --surface: #212121;
    --text: #f2f2f0;
    --muted: #a3a3a3;
    --primary: #5c87c4;
    --primary-dark: #0d2745;
    --gold: #cda268;
    --border: rgba(255, 255, 255, 0.09);
    --shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.5);
  }
}
:root[data-theme="dark"] {
  --bg: #141414;
  --bg-alt: #1c1c1c;
  --surface: #212121;
  --text: #f2f2f0;
  --muted: #a3a3a3;
  --primary: #5c87c4;
  --primary-dark: #0d2745;
  --gold: #cda268;
  --border: rgba(255, 255, 255, 0.09);
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.5);
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
p,
.hero p,
.section-head p,
.svc-card p,
.cs-body p {
  text-align: justify;
  text-justify: auto;
  -webkit-text-justify: kashida;
  word-spacing: -1px;
}
h1,
h2,
h3,
.brand {
  font-feature-settings:
    "liga" 1,
    "dlig" 1,
    "ss01" 1;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: "ThmanyahSans", "Tajawal", sans-serif;
  line-height: 1.75;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  overflow-x: hidden;
}
h1,
h2,
h3,
.brand {
  font-family: "ThmanyahSerifDisplay", "Cairo", sans-serif;
  font-weight: 800;
}
.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
a {
  color: inherit;
  text-decoration: none;
}
img {
  max-width: 100%;
  display: block;
}

button,
a,
.svc-icon,
.cs-body .tag,
input,
textarea {
  transition:
    background-color 0.3s ease,
    color 0.3s ease,
    border-color 0.3s ease,
    transform 0.15s ease;
}

.btn-primary:active {
  transform: scale(0.96);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.brand {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--accent);
}
.brand span {
  color: var(--accent);
}
.nav-links {
  display: flex;
  gap: 28px;
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-links a {
  position: relative;
  color: var(--muted);
  transition: color var(--dur-fast) var(--ease-smooth);
}
.nav-links a::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--dur-fast) var(--ease-smooth);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}
.nav-links a:hover::after {
  width: 100%;
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.theme-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    transform var(--dur-fast) var(--ease-smooth),
    border-color var(--dur-fast) var(--ease-smooth);
}
.theme-btn:hover {
  border-color: var(--accent);
}
.theme-btn:active {
  transform: scale(0.88) rotate(15deg);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.btn:focus-visible,
.theme-btn:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}
.btn-ghost:hover {
  border-color: var(--accent);
}
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  color: var(--text);
  cursor: pointer;
}

.hero {
  padding: 0 0 80px;
  position: relative;
  overflow: hidden;
}
.hero-hook {
  position: relative;
  overflow: hidden;
  min-height: calc(100svh - 76px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 24px;
}
.hero-lines {
  position: relative;
  z-index: 1;
  font-family: "ThmanyahSerifDisplay", "Cairo", sans-serif;
  font-weight: 800;
  margin: 0;
  text-align: center;
}
.hero-lines .line {
  display: block;
  line-height: 1.35;
}
.typewriter-wrap {
  position: relative;
  display: inline-block;
  vertical-align: bottom;
}
.typewriter-text {
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  width: 0;
  vertical-align: bottom;
  color: var(--accent);
}
.typewriter-text.animating {
  transition: width 1.7s steps(12, end);
}
.underline-draw {
  position: absolute;
  right: 0;
  bottom: -8px;
  height: 3px;
  width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
}
.underline-draw.drawn {
  transition: transform 0.8s ease;
  transform: scaleX(1);
}
#heroOrbFx {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  z-index: 0;
}
.hero-orb-ball {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: clamp(220px, 40vw, 380px);
  aspect-ratio: 1/1;
  margin: 18px auto 0;
  touch-action: none;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.scroll-hint {
  position: relative;
  z-index: 1;
  margin-top: 24px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0;
  transition: opacity 1s ease;
}
.scroll-hint.show {
  opacity: 1;
}
.scroll-hint span {
  display: block;
  margin-top: 4px;
  font-size: 1.1rem;
}
@media (prefers-reduced-motion: reduce) {
  .typewriter-text {
    width: auto !important;
  }
  .underline-draw {
    transform: scaleX(1) !important;
  }
  .scroll-hint {
    opacity: 1 !important;
  }
}
.hero-grid {
  display: block;
  max-width: 760px;
  margin: 0 auto;
  padding-top: 32px;
  text-align: center;
}
.hero-grid .hero-ctas {
  justify-content: center;
}
.hero-grid .eyebrow {
  display: block;
}
.eyebrow {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 14px;
}
.hero p {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 46ch;
  margin: 0 auto 34px;
}
.hero-ctas {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.hero-visual {
  aspect-ratio: 1/1;
  border-radius: 28px;
  background: linear-gradient(155deg, var(--primary-dark), var(--primary) 55%, var(--accent));
  position: relative;
  box-shadow: var(--shadow);
}
.hero-visual::before {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  width: 62%;
  height: 62%;
  top: 14%;
  left: 14%;
}

section {
  padding: 88px 0;
}
.section-head {
  max-width: 640px;
  margin-bottom: 48px;
}
.section-tag {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 10px;
}
.section-head :is(h1, h2) {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  margin-bottom: 14px;
}
.section-head p {
  color: var(--muted);
  font-size: 1.02rem;
}

.services {
  background: var(--bg-alt);
}
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.svc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition:
    transform var(--dur-normal) var(--ease-premium),
    box-shadow var(--dur-normal) var(--ease-premium),
    border-color var(--dur-normal) var(--ease-premium);
}
.svc-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: transparent;
}
.svc-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  transition: transform var(--dur-normal) var(--ease-premium);
}
.svc-card:hover .svc-icon {
  transform: scale(1.1) rotate(-6deg);
}
.svc-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
}
.svc-card p {
  color: var(--muted);
  font-size: 0.95rem;
  flex: 1;
}
.svc-card a {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
}

/* blog / case studies / articles / data */
.blog-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}
.blog-tab {
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
}
.blog-tab.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.cs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.cs-card {
  border: 1px solid var(--border);
  border-radius: 22px;
  overflow: hidden;
  background: var(--surface);
  transition:
    transform var(--dur-normal) var(--ease-premium),
    box-shadow var(--dur-normal) var(--ease-premium);
}
.cs-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}
.cs-top {
  height: 120px;
  background: linear-gradient(135deg, var(--accent-soft), var(--bg-alt));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-family: "ThmanyahSerifDisplay", "Cairo", sans-serif;
  font-weight: 900;
  font-size: 1.6rem;
}
.cs-body {
  padding: 22px;
}
.cs-body .tag {
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 10px;
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
}
.cs-body h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}
.cs-body p {
  color: var(--muted);
  font-size: 0.9rem;
}

.contact {
  background: var(--bg-alt);
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.field {
  margin-bottom: 16px;
}
.field label {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--muted);
}
.field input,
.field textarea {
  width: 100%;
  padding: 13px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
}
.field textarea {
  resize: vertical;
  min-height: 110px;
}
.contact-info {
  display: grid;
  gap: 20px;
}
.contact-info .item b {
  display: block;
  font-family: "ThmanyahSerifDisplay", "Cairo", sans-serif;
  margin-bottom: 4px;
}
.contact-info .item span {
  color: var(--muted);
  font-size: 0.9rem;
}
.contact-info .item a {
  color: var(--muted);
  transition: color var(--dur-fast) var(--ease-smooth);
}
.contact-info .item a:hover {
  color: var(--accent);
}

footer {
  border-top: 1px solid var(--border);
  padding: 36px 0;
}
.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-row .brand {
  font-size: 1rem;
}
.foot-links {
  display: flex;
  gap: 20px;
  font-size: 0.9rem;
  color: var(--muted);
}

@media (max-width: 860px) {
  .nav-links {
    display: none;
  }
  .menu-toggle {
    display: block;
  }
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .svc-grid,
  .cs-grid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
    animation: none !important;
  }
}

/* proof strip — horizontal auto-scrolling marquee */
.proof-strip {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  border-top: 1px solid var(--border);
  overflow: hidden;
  direction: ltr;
}
.proof-marquee {
  overflow: hidden;
  width: 100%;
  display: flex;
}
.proof-track {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  white-space: nowrap;
  animation: proofScroll 20s linear infinite;
  will-change: transform;
}
.proof-track > * {
  direction: rtl;
}
.proof-strip:hover .proof-track {
  animation-play-state: paused;
}
@keyframes proofScroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
.proof-pill {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.3;
  padding: 0 6px;
  vertical-align: middle;
}
.proof-main {
  font-size: 0.95rem;
  color: var(--text);
}
.proof-main b {
  color: var(--accent);
  font-family: "ThmanyahSerifDisplay", "Cairo", sans-serif;
  font-weight: 800;
  margin-inline-end: 4px;
}
.proof-sub {
  font-size: 0.72rem;
  color: var(--muted);
  margin-top: 2px;
}
.proof-sep {
  color: var(--border);
  font-size: 0.8rem;
  margin: 0 14px;
  vertical-align: middle;
}

/* tools: "coming soon" card state */

/* FAQ */
.faq-list {
  max-width: 820px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}
.faq-item {
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 22px;
  background: var(--surface);
  transition: border-color var(--dur-fast) var(--ease-smooth);
}
.faq-item:hover {
  border-color: var(--accent);
}
.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 1.02rem;
  list-style: none;
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary::after {
  content: "+";
  float: inline-start;
  margin-inline-end: 14px;
  color: var(--accent);
  font-weight: 900;
  display: inline-block;
  transition: transform var(--dur-fast) var(--ease-smooth);
}
.faq-item[open] summary::after {
  content: "+";
  transform: rotate(45deg);
}
.faq-item p {
  color: var(--muted);
  margin-top: 14px;
  line-height: 1.9;
  opacity: 0;
  transform: translateY(-6px);
  transition:
    opacity var(--dur-normal) var(--ease-smooth),
    transform var(--dur-normal) var(--ease-smooth);
}
.faq-item[open] p {
  opacity: 1;
  transform: translateY(0);
}

/* closing CTA */
.closing-cta {
  background: linear-gradient(160deg, var(--primary-dark), var(--primary));
  color: #fff;
  text-align: center;
  padding: 88px 0;
}
.closing-cta h2 {
  color: #fff;
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  margin-bottom: 16px;
}
.closing-cta p {
  color: #c9d6ea;
  max-width: 56ch;
  margin: 0 auto 32px;
  font-size: 1.05rem;
}

/* ===== المدونة: الغلاف، البطاقات، ومحتوى المقالة (كتل) ===== */
:root {
  --success: #3e8e6d;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --success: #5bb18f;
  }
}
:root[data-theme="dark"] {
  --success: #5bb18f;
}

/* أيقونات */
.icon {
  width: 24px;
  height: 24px;
  display: block;
  flex-shrink: 0;
}

/* ---------- بطاقات المدونة ---------- */
a.cs-card {
  display: block;
  color: inherit;
}
.cs-cover {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--accent-soft);
}
.cs-cover picture {
  display: block;
  width: 100%;
  height: 100%;
}
.cs-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.cs-card:hover .cs-cover img {
  transform: scale(1.03);
}
.cs-date {
  display: block;
  margin-top: 14px;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- رأس المقالة ---------- */
.post {
  padding: 56px 0 80px;
}
.post-head {
  max-width: 820px;
  margin-inline: auto;
  padding-bottom: 28px;
}
.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.85rem;
}
.post-meta .tag {
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 700;
  font-size: 0.78rem;
  padding: 4px 14px;
  border-radius: 999px;
}
.post-head h1 {
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  line-height: 1.35;
  margin-bottom: 16px;
}
.post-lead {
  color: var(--muted);
  font-size: 1.15rem;
  line-height: 1.9;
}

.post-cover {
  aspect-ratio: 16/9;
  border-radius: 24px;
  overflow: hidden;
  background: var(--accent-soft);
  border: 1px solid var(--border);
  margin-bottom: 12px;
}
.post-cover picture {
  display: block;
  width: 100%;
  height: 100%;
}
.post-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
