/* خلفية الصفحة بالكامل أبيض سكري دافئ */
html, body {
  background: #faf8f3 !important;
  color: #182230 !important;
  overflow-x: hidden !important;
}

header, .topbar, .top-bar {
  background: #ffffff !important;
  border-bottom: 1px solid #e5dfd3 !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  padding: 10px 14px !important;
}

.hq-hidden-fab {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: scale(0.01) !important;
}

.hq-demo-shell { width: 100% !important; max-width: none !important; box-sizing: border-box; }

@keyframes barberRibbon {
  0% { background-position: 0 0; }
  100% { background-position: 84px 0; }
}

@keyframes barberSpin {
  0% { transform: translateY(0); }
  100% { transform: translateY(-28px); }
}

#hq-studio {
  --ink: #0f172a;
  --soft: #475569;
  position: relative;
  isolation: isolate;
  box-sizing: border-box;
  width: min(980px, calc(100% - 24px));
  margin: clamp(16px, 3vh, 36px) auto;
  padding: clamp(24px, 4vw, 40px) clamp(18px, 4vw, 38px) clamp(20px, 4vw, 36px);
  overflow: hidden;
  text-align: start;
  font-family: inherit;
  line-height: 1.6;
  color: var(--ink);
  background: #ffffff;
  border: 1.5px solid #e2dacd;
  border-radius: 26px;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.07);
}

/* شريط عمود الحلاقة الكلاسيكي المتحرك (أحمر - أبيض - أزرق) */
#hq-studio::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 9px;
  background: repeating-linear-gradient(
    -45deg,
    #b45309 0px,
    #b45309 14px,
    #ffffff 14px,
    #ffffff 28px,
    #154535 28px,
    #154535 42px,
    #ffffff 42px,
    #ffffff 56px
  );
  background-size: 84px 84px;
  animation: barberRibbon 2.8s linear infinite;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

#hq-studio *, #hq-studio *::before, #hq-studio *::after { box-sizing: border-box; }
#hq-studio [hidden] { display: none !important; }

#hq-studio .hq-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}

#hq-studio .hq-brand-title {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* أيقونة عمود الحلاقة الجانبية */
#hq-studio .hq-pole-badge {
  flex: none;
  width: clamp(54px, 11vw, 72px);
  height: clamp(78px, 15vw, 102px);
  padding: 6px;
  border-radius: 20px;
  background: linear-gradient(145deg, #ffffff, #f3efe6);
  border: 1.5px solid #e2d9c8;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  display: grid;
  place-items: center;
}
#hq-studio .hq-pole-badge svg {
  width: 100%;
  height: 100%;
  display: block;
}
#hq-studio .hq-pole-stripes {
  animation: barberSpin 2.4s linear infinite;
}

#hq-studio .hq-kicker {
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  color: #154535;
  background: #f4f1e8;
  border: 1px solid #d8cfbc;
  padding: 3px 11px;
  border-radius: 999px;
  margin-bottom: 6px;
}

#hq-studio-title {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  font-size: clamp(23px, 4.8vw, 40px);
  line-height: 1.28;
}
#hq-studio-title em {
  color: #b45309;
  font-style: normal;
}

/* دليل الاستعمال مفتوح دائماً في الأعلى مع تباين نص عالٍ */
#hq-studio .hq-guide-box {
  margin-top: 20px;
}
#hq-studio .hq-guide {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 16px 18px !important;
  background: #fcfaf5 !important;
  border: 1.5px solid #e4dccb !important;
  border-radius: 18px !important;
  color: #0f172a !important;
  font-size: clamp(14px, 3.6vw, 16px) !important;
  line-height: 1.65 !important;
}
#hq-studio .hq-guide h1,
#hq-studio .hq-guide h2,
#hq-studio .hq-guide h3,
#hq-studio .hq-guide h4,
#hq-studio .hq-guide strong,
#hq-studio .hq-guide b {
  color: #0f172a !important;
}
#hq-studio .hq-guide > p,
#hq-studio .hq-guide > div:first-of-type {
  color: #334155 !important;
}

#hq-studio .hq-roles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

#hq-studio .hq-role {
  --accent: #16a34a;
  --tint: #dcfce7;
  --bg-card: #f8fcf9;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: clamp(16px, 3vw, 26px);
  border-radius: 18px;
  background: var(--bg-card);
  border: 1.5px solid #d9e8de;
  border-inline-start: 5px solid var(--accent);
}

#hq-studio .hq-tg {
  --accent: #154535;
  --tint: #e2ece9;
  --bg-card: #f8faf9;
  border-color: #d4e2dd;
}

#hq-studio .hq-role.hq-active {
  border-color: var(--accent);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

#hq-studio .hq-role-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

#hq-studio .hq-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: clamp(44px, 10vw, 54px);
  aspect-ratio: 1;
  border-radius: 14px;
  background: var(--tint);
  color: var(--accent);
}
#hq-studio .hq-icon svg { display: block; width: 60%; height: 60%; }

#hq-studio h3 {
  margin: 0;
  color: #0f172a;
  font-weight: 800;
  font-size: clamp(19px, 4.5vw, 26px);
  line-height: 1.35;
}

#hq-studio .hq-role p, #hq-studio .hq-role small {
  margin: 0;
  color: var(--soft);
  font-size: clamp(14px, 3.8vw, 16.5px);
}

#hq-studio button {
  min-height: 48px;
  padding: 11px 16px;
  border-radius: 13px;
  font: inherit;
  font-size: clamp(15px, 4vw, 17px);
  font-weight: 800;
  line-height: 1.4;
  cursor: pointer;
}

#hq-studio .hq-role button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  margin-top: 4px;
  border: 0;
  background: var(--accent);
  color: #ffffff;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.14);
}
#hq-studio .hq-role button span { font: 22px/1 Arial; }

#hq-studio .hq-auto {
  color: #154535;
  background: #f4f1e8;
  border: 1.5px solid #d8cfbc;
  font-size: 14.5px;
  min-height: 42px;
  padding: 6px 14px;
}
#hq-studio .hq-auto:disabled { opacity: 0.55; cursor: wait; }
#hq-studio button:hover:enabled { filter: brightness(0.95); }

@media (max-width: 680px) {
  #hq-studio {
    width: calc(100% - 16px);
    margin: 10px auto 20px;
    padding: 20px 14px 16px;
    border-radius: 20px;
  }
  #hq-studio .hq-brand-title {
    gap: 12px;
  }
  #hq-studio .hq-roles {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 14px;
  }
  #hq-studio .hq-role {
    padding: 15px 14px;
    gap: 10px;
  }
  #hq-studio .hq-guide {
    padding: 12px 14px !important;
  }
}

/* hq-steps-contrast:start */
#hq-studio .hq-guide [class],
#hq-studio .hq-guide div,
#hq-studio .hq-guide p,
#hq-studio .hq-guide li {
  color: #e2e8f0 !important;
}

#hq-studio .hq-guide > h1,
#hq-studio .hq-guide > h2,
#hq-studio .hq-guide > h3,
#hq-studio .hq-guide > h4,
#hq-studio .hq-guide > p:first-of-type,
#hq-studio .hq-guide > div:first-child {
  color: #0f172a !important;
}

/* البطاقات الثلاث نفسها */
#hq-studio .hq-guide div[style],
#hq-studio .hq-guide li {
  background: #142922 !important;
  border: 1.5px solid #27473c !important;
  border-inline-start: 5px solid #154535 !important;
  color: #f1f5f9 !important;
}

#hq-studio .hq-guide div[style]:nth-of-type(2),
#hq-studio .hq-guide li:nth-child(2) {
  border-inline-start-color: #b45309 !important;
}

/* إجبار كل الكلمات المميزة والرموز داخل البطاقات على الوضوح التام */
#hq-studio .hq-guide div[style] *,
#hq-studio .hq-guide li * {
  color: #f8fafc !important;
}

#hq-studio .hq-guide div[style] code,
#hq-studio .hq-guide div[style] b,
#hq-studio .hq-guide div[style] strong,
#hq-studio .hq-guide li code,
#hq-studio .hq-guide li b,
#hq-studio .hq-guide li strong {
  color: #f6d774 !important;
  background: rgba(246, 215, 116, 0.16) !important;
  padding: 1px 6px !important;
  border-radius: 6px !important;
  font-weight: 800 !important;
}
/* hq-steps-contrast:end */

/* hq-palette:start */
body:has(#hq-studio), #hq-studio {
  --hq-paper:    #f7f7f2;
  --hq-surface:  #ffffff;
  --hq-row:      #f3f6f3;
  --hq-line:     #d5dfd9;
  --hq-ink:      #19382f;
  --hq-muted:    #475d54;

  --hq-green:    #176749;
  --hq-green-hi: #105239;
  --hq-mint:     #e2f1e9;

  --hq-blue:     #205e91;
  --hq-blue-hi:  #164b76;
  --hq-ice:      #e5eff8;
}

body:has(#hq-studio) {
  background: var(--hq-paper) !important;
  border-top-color: var(--hq-green) !important;
}

#hq-studio {
  --ink: var(--hq-ink);
  --soft: var(--hq-muted);
  color: var(--hq-ink) !important;
  background: var(--hq-surface) !important;
  border-color: var(--hq-line) !important;
  box-shadow: 0 12px 36px rgb(25 56 47 / 8%) !important;
}

/* شريط الحلّاق يستعمل نفس لوني البطاقتين. */
#hq-studio::before {
  background: repeating-linear-gradient(
    120deg,
    var(--hq-green) 0 14px, var(--hq-paper) 14px 27px,
    var(--hq-blue) 27px 41px, var(--hq-paper) 41px 54px
  ) !important;
}

#hq-studio-title { color: var(--hq-ink) !important; }
#hq-studio-title em { color: var(--hq-blue) !important; }

#hq-studio .hq-head :is(.hq-kicker,.hq-badge,.hq-eyebrow,[class*="pill" i]) {
  color: var(--hq-green) !important;
  background: var(--hq-mint) !important;
  border-color: var(--hq-line) !important;
}

/* دليل الخطوات بخلفية هادئة حتى تبقى أزرار التجربة أبرز عناصر الصفحة. */
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) {
  color: var(--hq-ink) !important;
  background: var(--hq-surface) !important;
  border-color: var(--hq-line) !important;
  box-shadow: none !important;
}
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) :where(div,section,article,li,span,b,strong,small) {
  color: var(--hq-ink) !important;
  background: transparent !important;
  border-color: var(--hq-line) !important;
  box-shadow: none !important;
}
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) :where(li,article,.step,.step-card,.guide-step,[data-step],div[style*="background" i],div:has(> p)) {
  background: var(--hq-row) !important;
}
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) :where(h2,h3,h4,summary) { color: var(--hq-ink) !important; }
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) :where(p,small) { color: var(--hq-muted) !important; }
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) :where(mark,kbd,code,.chip,.badge,.step-number,[class*="step-num"],span[style*="background" i]) {
  background: var(--hq-mint) !important;
  color: var(--hq-green-hi) !important;
  border-color: var(--hq-line) !important;
}
:is(
  #hq-studio .hq-guide,
  #hq-studio .hq-instructions,
  #hq-studio .instructions,
  #hq-studio > details,
  #hq-studio > :is(div,section,aside,article):has(+ .hq-roles):not(.hq-head):not(:has(#hq-studio-title))
) a { color: var(--hq-blue) !important; }

/* كل قناة تستخدم لونًا واحدًا في الأيقونة والحافة والزر. */
#hq-studio .hq-wa {
  --accent: var(--hq-green);
  --tint: var(--hq-mint);
  --hover: var(--hq-green-hi);
}
#hq-studio .hq-tg {
  --accent: var(--hq-blue);
  --tint: var(--hq-ice);
  --hover: var(--hq-blue-hi);
}
#hq-studio .hq-role {
  background: var(--hq-surface) !important;
  border-color: var(--hq-line) !important;
  border-inline-start-color: var(--accent) !important;
  box-shadow: none !important;
}
#hq-studio .hq-role.hq-active { border-color: var(--accent) !important; }
#hq-studio .hq-role h3 { color: var(--hq-ink) !important; }
#hq-studio .hq-role :is(p,small) { color: var(--hq-muted) !important; }
#hq-studio .hq-role .hq-icon {
  background: var(--tint) !important;
  color: var(--accent) !important;
}
#hq-studio .hq-role button {
  background: var(--accent) !important;
  color: white !important;
  border-color: var(--accent) !important;
  box-shadow: none !important;
}
#hq-studio .hq-role button:hover:enabled { background: var(--hover) !important; }

/* شريط الأدوات وزر العرض التلقائي. */
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) {
  background: var(--hq-surface) !important;
  border-color: var(--hq-line) !important;
}
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) a[href="/"] { color: var(--hq-ink) !important; }
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) :is(.badge,.pill,[class*="status" i],span[style*="background" i]) {
  color: var(--hq-green-hi) !important;
  background: var(--hq-mint) !important;
}
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) :is([id*="reset" i],[class*="reset" i],[onclick*="reset" i]) {
  background: var(--hq-row) !important;
  color: var(--hq-ink) !important;
  border-color: var(--hq-line) !important;
}
#hq-studio .hq-auto,
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) :is(button,a):is([id*="auto" i],[class*="auto" i],[onclick*="auto" i]) {
  background: var(--hq-blue) !important;
  border-color: var(--hq-blue) !important;
  color: white !important;
}
body:has(#hq-studio) > :is(
  header, nav, .topbar, .top-bar, .toolbar, #topbar,
  div:has(a[href="/"]):has(button):not(:has(#hq-studio))
) :is(a[href*="pricing"],[class*="subscribe" i],[id*="subscribe" i]) {
  background: var(--hq-green) !important;
  color: white !important;
}
#hq-studio :is(button,a,summary):focus-visible {
  outline: 3px solid var(--hq-blue) !important;
  outline-offset: 3px;
}
/* hq-palette:end */

/* hq-barber-pole:start */
body:has(#hq-studio), #hq-studio.hq-pole-board {
  --pole-red: #dc2626;
  --pole-blue: #2563eb;
  --tg-blue: #0284c7;
  --tg-blue-hi: #0369a1;
  --tg-tint: rgba(2, 132, 199, 0.18);
  --wa-green: #16a34a;
  --wa-green-hi: #15803d;
  --wa-tint: rgba(22, 163, 74, 0.18);

  --pole-stripes: repeating-linear-gradient(135deg,
    var(--pole-red) 0 12.5%, #f8fafc 12.5% 25%,
    var(--pole-blue) 25% 37.5%, #f8fafc 37.5% 50%);

  --hq-paper: #0b111a; --hq-surface: #131c2a; --hq-row: #182334;
  --hq-line: #26364d; --hq-ink: #f8fafc; --hq-muted: #cbd5e1;
  background: #0b111a !important;
}

#hq-studio.hq-pole-board {
  --ink: #f8fafc; --soft: #cbd5e1;
  position: relative; overflow: hidden;
  background: #131c2a !important; color: #f8fafc !important;
  border-color: #26364d !important; box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45) !important;
}
#hq-studio.hq-pole-board::before { content: none !important; }
#hq-studio.hq-pole-board, #hq-studio.hq-pole-board :is(h1,h2,h3,button,summary) { font-family: inherit !important; }

#hq-studio #hq-studio-title { color: #ffffff !important; }
#hq-studio #hq-studio-title em { color: #f87171 !important; font-style: normal !important; }

/* دليل الخطوات داكن أنيق بنصوص ناصعة الوضوح */
#hq-studio.hq-pole-board .hq-white-guide { position: relative; overflow: hidden; }
#hq-studio.hq-pole-board .hq-white-guide,
#hq-studio.hq-pole-board .hq-white-guide :where(section,article,div,ol,ul,li) {
  background: #182334 !important;
  color: #f1f5f9 !important;
  border-color: #293a54 !important;
  box-shadow: none !important;
}
#hq-studio .hq-white-guide :is(h2,h3,h4,strong,b) { color: #ffffff !important; font-weight: 800 !important; }
#hq-studio .hq-white-guide :is(p,small,span) { color: #cbd5e1 !important; }
#hq-studio .hq-white-guide :is(mark,kbd,code) {
  background: rgba(56, 189, 248, 0.16) !important;
  color: #7dd3fc !important;
  border: 1px solid rgba(56, 189, 248, 0.35) !important;
  padding: 1px 6px !important; border-radius: 6px !important; font-weight: 800 !important;
}

/* تليجرام بالأزرق الأصيل، وواتساب بالأخضر الأصيل */
#hq-studio .hq-roles { direction: rtl; }
#hq-studio.hq-pole-board .hq-tg { order: 0 !important; --accent: var(--tg-blue); --tint: var(--tg-tint); }
#hq-studio.hq-pole-board .hq-wa { order: 1 !important; --accent: var(--wa-green); --tint: var(--wa-tint); }

#hq-studio.hq-pole-board .hq-role {
  background: #182334 !important;
  border-color: #293a54 !important;
  border-inline-start: 4px solid var(--accent) !important;
}
#hq-studio.hq-pole-board .hq-role h3 { color: #ffffff !important; }
#hq-studio.hq-pole-board .hq-role p { color: #cbd5e1 !important; }
#hq-studio.hq-pole-board .hq-icon { color: #ffffff !important; background: var(--accent) !important; }
#hq-studio.hq-pole-board .hq-icon svg { color: #ffffff !important; fill: currentColor !important; }

#hq-studio.hq-pole-board .hq-tg button {
  background: var(--tg-blue) !important; border-color: #38bdf8 !important; color: #ffffff !important;
}
#hq-studio.hq-pole-board .hq-tg button:hover:enabled { background: var(--tg-blue-hi) !important; }

#hq-studio.hq-pole-board .hq-wa button {
  background: var(--wa-green) !important; border-color: #22c55e !important; color: #ffffff !important;
}
#hq-studio.hq-pole-board .hq-wa button:hover:enabled { background: var(--wa-green-hi) !important; }

#hq-studio.hq-pole-board .hq-auto, .hq-pole-toolbar .hq-pole-run {
  background: var(--pole-blue) !important; border-color: #60a5fa !important; color: #ffffff !important;
}
.hq-pole-toolbar { background: #131c2a !important; border-bottom: 1px solid #26364d !important; }
.hq-pole-toolbar :is(a,button):not(.hq-pole-run) {
  background: #182334 !important; color: #f8fafc !important; border-color: #2e405b !important;
}

[data-hq-edge] {
  display: block; position: absolute; pointer-events: none; z-index: 1;
  background: var(--pole-stripes) 0 0 / 40px 40px repeat;
  animation: hq-pole-flow 2.4s linear infinite;
}
[data-hq-edge="top"], [data-hq-edge="bottom"] { left: 0; right: 0; height: 5px; }
[data-hq-edge="top"] { top: 0; }
[data-hq-edge="bottom"] { bottom: 0; animation-direction: reverse; }
[data-hq-edge="left"], [data-hq-edge="right"] { top: 0; bottom: 0; width: 2px; }
[data-hq-edge="left"] { left: 0; animation-direction: reverse; }
[data-hq-edge="right"] { right: 0; }
body > [data-hq-edge] { position: fixed; height: 3px; z-index: 100; }
#hq-studio .hq-white-guide > :is([data-hq-edge="top"],[data-hq-edge="bottom"]) { height: 2px; }
@keyframes hq-pole-flow { to { background-position: 40px 0; } }

#hq-studio .hq-live-pole {
  --chrome: linear-gradient(90deg,#94a3b8,#ffffff 38%,#cbd5e1 65%,#64748b);
  display: inline-block; position: relative; vertical-align: middle; flex: none;
  width: clamp(26px, 2.6vw, 34px); height: clamp(44px, 4.6vw, 58px); border-radius: 5px;
  background: var(--chrome) center top / 100% 5px no-repeat, var(--chrome) center bottom / 100% 5px no-repeat;
}
#hq-studio .hq-live-pole::before {
  content: ""; position: absolute; inset: 4px 3px; border: 1px solid #94a3b8; border-radius: 3px;
  background: linear-gradient(90deg,#0f172a55,#ffffff66 24%,transparent 52%,#0f172a55),
              var(--pole-stripes) 0 0 / 24px 24px repeat;
  animation: hq-pole-turn 1.8s linear infinite;
}
@keyframes hq-pole-turn { to { background-position: 0 0, 0 24px; } }
/* hq-barber-pole:end */
