/* Public documentation pages (/docs): one page per product */
.docs { --dc-bg: #313338; --dc-fg: #dbdee1; --dc-mut: #949ba4; }
.docs main { max-width: 1240px; margin: 0 auto; padding: 96px 20px 60px; }
.docs h1, .docs h2, .docs h3 { letter-spacing: 0; }

/* hub */
.dhub-head { text-align: center; margin: 24px 0 36px; }
.dhub-head h1 { font-size: clamp(28px, 4.5vw, 44px); margin: 10px 0; }
.dhub-head p { color: var(--mut, #9aa0ac); max-width: 640px; margin: 0 auto; line-height: 1.8; }
.dgrid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.dcard { display: flex; flex-direction: column; gap: 12px; padding: 22px; border-radius: 18px; border: 1px solid rgba(255, 255, 255, .08); background: linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .015)); color: inherit; text-decoration: none; transition: transform .2s, border-color .2s; }
.dcard:hover { transform: translateY(-3px); border-color: rgba(91, 155, 255, .5); }
.dcard .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: rgba(91, 155, 255, .14); color: #7cb0ff; }
.dcard .ic svg { width: 26px; height: 26px; }
.dcard h3 { margin: 0; font-size: 20px; }
.dcard p { margin: 0; color: var(--mut, #9aa0ac); line-height: 1.7; }
.dcard ul { margin: 0; padding-inline-start: 18px; color: var(--mut, #9aa0ac); line-height: 1.9; font-size: 14px; }
.dcard .go { margin-top: auto; font-weight: 700; color: #7cb0ff; }

/* product page */
.dlayout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 32px; align-items: start; }
.dtoc { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 2px; padding: 14px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); max-height: calc(100vh - 120px); overflow: auto; }
.dtoc b { font-size: 12px; text-transform: uppercase; opacity: .6; padding: 4px 8px 8px; }
.dtoc a { padding: 8px 10px; border-radius: 8px; color: inherit; text-decoration: none; font-size: 14px; opacity: .8; }
.dtoc a:hover, .dtoc a.on { background: rgba(91, 155, 255, .14); opacity: 1; }
.dtoc .back { margin-bottom: 8px; opacity: 1; font-weight: 700; }
.dhero { padding: 28px; border-radius: 20px; border: 1px solid rgba(255, 255, 255, .08); background: radial-gradient(900px 260px at 10% 0, rgba(91, 155, 255, .16), transparent), rgba(255, 255, 255, .03); margin-bottom: 28px; }
.dhero .row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.dhero .ic { width: 58px; height: 58px; border-radius: 16px; display: grid; place-items: center; background: rgba(91, 155, 255, .16); color: #7cb0ff; }
.dhero .ic svg { width: 30px; height: 30px; }
.dhero h1 { margin: 0; font-size: clamp(26px, 4vw, 38px); }
.dhero p { margin: 14px 0 0; line-height: 1.9; color: var(--mut, #aab0bc); max-width: 820px; }
.dhero .acts { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.dsec { margin-bottom: 46px; scroll-margin-top: 90px; }
.dsec > h2 { font-size: 26px; margin: 0 0 6px; }
.dsec > .sub { color: var(--mut, #9aa0ac); margin: 0 0 18px; line-height: 1.8; }
.feats { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.feat { padding: 18px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); }
.feat .ic { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: rgba(91, 155, 255, .14); color: #7cb0ff; margin-bottom: 10px; }
.feat .ic svg { width: 20px; height: 20px; }
.feat h3 { margin: 0 0 6px; font-size: 16px; }
.feat p { margin: 0; color: var(--mut, #9aa0ac); line-height: 1.75; font-size: 14px; }

.steps2 { counter-reset: s; display: grid; gap: 12px; }
.steps2 > div { counter-increment: s; display: flex; gap: 14px; padding: 16px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); }
.steps2 > div::before { content: counter(s); flex: 0 0 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: #3b82f6; color: #fff; font-weight: 800; }
.steps2 h3 { margin: 2px 0 4px; font-size: 16px; }
.steps2 p { margin: 0; color: var(--mut, #9aa0ac); line-height: 1.75; font-size: 14px; }
.steps2 code, .dsec code, .cmd code { background: rgba(255, 255, 255, .08); padding: 1px 6px; border-radius: 6px; font-size: .92em; direction: ltr; unicode-bidi: embed; }

.gal { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); }
.shot { border-radius: 16px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); overflow: hidden; }
.shot .pic { padding: 16px; background: #1e1f22; display: grid; place-items: center; min-height: 160px; }
.shot .pic > img { max-width: 100%; border-radius: 10px; display: block; }
.shot figcaption, .shot .cap { padding: 12px 16px; font-size: 14px; color: var(--mut, #9aa0ac); line-height: 1.7; }
.shot .cap b { color: inherit; display: block; margin-bottom: 2px; }

/* a Discord-like message */
.dm { width: 100%; background: var(--dc-bg); color: var(--dc-fg); border-radius: 10px; padding: 14px 16px; text-align: start; direction: ltr; font-family: "Inter", "Tajawal", sans-serif; font-size: 15px; line-height: 1.45; }
.dm[dir=rtl] { direction: rtl; }
.dm .who { display: flex; gap: 12px; }
.dm .av { width: 40px; height: 40px; border-radius: 50%; flex: none; background: #5865f2 center / cover; }
.dm .nm { font-weight: 600; margin-bottom: 2px; }
.dm .nm em { font-style: normal; background: #5865f2; color: #fff; border-radius: 4px; padding: 0 5px; font-size: 10px; margin-inline-start: 6px; vertical-align: 2px; font-weight: 700; }
.dm .nm small { color: var(--dc-mut); font-weight: 400; margin-inline-start: 6px; font-size: 12px; }
.dm .body { min-width: 0; flex: 1; }
.dm .mention { background: rgba(88, 101, 242, .3); color: #c9cdfb; border-radius: 3px; padding: 0 2px; }
.dm .emb { margin-top: 6px; border-inline-start: 4px solid #4a90e2; background: #2b2d31; border-radius: 4px; padding: 10px 14px; max-width: 520px; }
.dm .emb .t { font-weight: 700; margin-bottom: 4px; }
.dm .emb .d { white-space: pre-line; color: #dbdee1; font-size: 14px; }
.dm .emb .fl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; font-size: 13px; }
.dm .emb .fl b { display: block; font-size: 12px; color: #b5bac1; }
.dm .emb img { max-width: 100%; border-radius: 6px; margin-top: 8px; display: block; }
.dm .emb .ft { margin-top: 8px; font-size: 12px; color: var(--dc-mut); }
.dm .big { max-width: 100%; border-radius: 8px; margin-top: 6px; display: block; }
.dm .btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.dm .btns span { padding: 6px 14px; border-radius: 4px; font-size: 14px; font-weight: 500; background: #4e5058; color: #fff; }
.dm .btns .primary { background: #5865f2; } .dm .btns .success { background: #248046; } .dm .btns .danger { background: #da373c; }
.dm .sel { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; padding: 9px 12px; border-radius: 4px; border: 1px solid #1e1f22; background: #1e1f22; color: #b5bac1; font-size: 14px; max-width: 520px; }
.dm .md1 { font-size: 20px; font-weight: 700; margin: 6px 0 2px; }
.dm code { background: #1e1f22; border-radius: 4px; padding: 1px 4px; }
.dm pre { background: #1e1f22; border: 1px solid #1a1b1e; border-radius: 4px; padding: 8px 10px; margin: 6px 0 0; font-size: 13px; white-space: pre-wrap; }

/* commands */
.dtools { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.dtools input { flex: 1; min-width: 220px; padding: 11px 14px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .04); color: inherit; font: inherit; }
.dchips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.dchips button { padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .12); background: transparent; color: inherit; cursor: pointer; font: inherit; font-size: 13px; }
.dchips button.on { background: #3b82f6; border-color: #3b82f6; color: #fff; }
.cmds { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); }
.cmd { padding: 14px 16px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); }
.cmd .top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.cmd .nmx { font-weight: 800; font-size: 16px; direction: ltr; unicode-bidi: embed; }
.cmd .who2 { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: rgba(255, 255, 255, .08); white-space: nowrap; }
.cmd p { margin: 6px 0; color: var(--mut, #9aa0ac); font-size: 14px; line-height: 1.7; }
.cmd .al { font-size: 12px; opacity: .8; }
.cmd .us { margin-top: 6px; font-size: 13px; }
.cmd .us code { display: block; margin-top: 3px; padding: 5px 8px; }
.dcount { color: var(--mut, #9aa0ac); font-size: 13px; margin-bottom: 8px; }

.callout { padding: 14px 16px; border-radius: 12px; border: 1px solid rgba(245, 158, 11, .4); background: rgba(245, 158, 11, .08); line-height: 1.8; margin-top: 14px; font-size: 14px; }
.qa { display: grid; gap: 10px; }
.qa details { border: 1px solid rgba(255, 255, 255, .08); border-radius: 12px; background: rgba(255, 255, 255, .03); padding: 4px 16px; }
.qa summary { cursor: pointer; padding: 12px 0; font-weight: 700; }
.qa details p { margin: 0 0 12px; color: var(--mut, #9aa0ac); line-height: 1.8; font-size: 14px; }
.dcta { margin-top: 30px; padding: 28px; border-radius: 20px; text-align: center; border: 1px solid rgba(91, 155, 255, .3); background: radial-gradient(600px 200px at 50% 0, rgba(91, 155, 255, .18), transparent); }
.dcta h2 { margin: 0 0 8px; }
.dcta p { color: var(--mut, #9aa0ac); margin: 0 0 16px; }

@media (max-width: 900px) {
  .dlayout { grid-template-columns: 1fr; }
  .dtoc { position: static; flex-direction: row; flex-wrap: wrap; max-height: none; }
  .gal { grid-template-columns: 1fr; }
}
