/* The blog: plain CSS (no Tailwind), Digital Chotu purple and orange. Logical properties so right-to-left needs no second set of rules. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #1a0838;
  color: rgba(255, 255, 255, 0.86);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.75;
  overflow-wrap: break-word;
}
a { color: #ffb27a; }
a:focus-visible { outline: 2px solid #ff7a2e; outline-offset: 2px; }
h1, h2, h3 { color: #fff; font-family: 'Space Grotesk', 'Inter', sans-serif; line-height: 1.25; }
img { max-width: 100%; }

.blog-wrap { width: 100%; max-width: 68rem; margin-inline: auto; padding-inline: 1.25rem; }

.blog-header { border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.blog-header__row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; padding-block: 0.9rem; }
.blog-logo { display: block; height: 3rem; padding: 5px; border-radius: 8px; background: #fff; }
.blog-logo img { display: block; height: 100%; width: auto; }
.blog-nav { display: flex; gap: 1.25rem; font-size: 0.9rem; }
.blog-nav a, .blog-footer a { color: rgba(255, 255, 255, 0.8); text-decoration: none; }
.blog-nav a:hover, .blog-footer a:hover, .blog-nav a[aria-current] { color: #ff9a57; }
.blog-langs { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-inline-start: auto; }
.blog-langs a { padding: 0.25rem 0.75rem; border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 999px; color: #fff; font-size: 0.8125rem; line-height: 1.9; text-decoration: none; }
.blog-langs a:hover { border-color: #ff5c00; }
.blog-langs a[aria-current] { border-color: #ff5c00; background: rgba(255, 92, 0, 0.22); }

.blog-intro { padding-block: 3rem 2rem; max-width: 46rem; }
.blog-intro h1 { margin: 0 0 0.75rem; font-size: clamp(2rem, 5vw, 3rem); }
.blog-intro p { margin: 0; }

.blog-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); padding-block-end: 3rem; }
.blog-card { position: relative; display: flex; flex-direction: column; padding: 1.5rem; border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 1.25rem; background: rgba(255, 255, 255, 0.04); }
.blog-card:hover { border-color: rgba(255, 92, 0, 0.6); }
.blog-card time, .blog-meta { color: rgba(255, 255, 255, 0.55); font-size: 0.8125rem; }
.blog-card h2 { margin: 0.5rem 0; font-size: 1.25rem; }
.blog-card h2 a { color: #fff; text-decoration: none; }
/* the whole card is clickable through its title link */
.blog-card h2 a::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.blog-card p { margin: 0 0 1rem; font-size: 0.95rem; }
.blog-card__more { margin-block-start: auto; color: #ff7a2e; font-size: 0.9rem; font-weight: 600; }

/* ---- article: hero, contents list, body */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

.blog-hero { padding-block: 2rem 2.25rem; border-bottom: 1px solid rgba(255, 255, 255, 0.08); background: radial-gradient(ellipse at 15% 0%, rgba(255, 92, 0, 0.2), transparent 55%), radial-gradient(ellipse at 90% 100%, rgba(110, 66, 190, 0.35), transparent 60%); }
.blog-hero__inner > * { max-width: 48rem; }
.blog-crumbs { display: flex; gap: 0.5rem; font-size: 0.85rem; color: rgba(255, 255, 255, 0.45); }
.blog-crumbs a { color: rgba(255, 255, 255, 0.75); text-decoration: none; }
.blog-hero h1 { margin: 1.25rem 0 0.75rem; font-size: clamp(2.1rem, 6vw, 3.5rem); line-height: 1.12; }
.blog-standfirst { margin: 0 0 1.25rem; color: rgba(255, 255, 255, 0.9); font-size: clamp(1.1rem, 2.2vw, 1.3rem); line-height: 1.65; }
.blog-meta { margin: 0; color: rgba(255, 255, 255, 0.6); font-size: 0.85rem; }
.blog-draft { display: inline-block; margin: 1rem 0 0; padding: 0.2rem 0.75rem; border: 1px dashed #ffb27a; border-radius: 999px; color: #ffb27a; font-size: 0.75rem; font-weight: 700; }
.blog-card__meta { margin: 0; color: rgba(255, 255, 255, 0.55); font-size: 0.8125rem; }
.blog-card__meta .blog-draft { margin: 0 0 0 0.5rem; }

.blog-layout { display: grid; gap: 1.5rem 3.5rem; padding-block: 2rem 3rem; }
.blog-main { width: 100%; max-width: 46rem; min-width: 0; margin-inline: auto; }
.blog-layout--toc .blog-main { margin-inline: 0; }
.blog-toc { padding: 1rem 1.1rem; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 1rem; background: rgba(255, 255, 255, 0.03); font-size: 0.875rem; line-height: 1.5; }
.blog-toc p { margin: 0 0 0.5rem; color: #fff; font-weight: 700; }
.blog-toc ul { margin: 0; padding: 0; list-style: none; }
.blog-toc a { display: block; padding-block: 0.3rem; color: rgba(255, 255, 255, 0.75); text-decoration: none; }
.blog-toc a:hover { color: #ff9a57; }
/* narrow screens: the contents list becomes compact buttons, so the article starts sooner */
@media (max-width: 61.99rem) {
  .blog-toc ul { display: flex; flex-wrap: wrap; gap: 0.4rem; }
  .blog-toc a { padding: 0.3rem 0.7rem; border: 1px solid rgba(255, 255, 255, 0.18); border-radius: 999px; font-size: 0.8rem; }
}
@media (min-width: 62rem) {
  .blog-layout--toc { grid-template-columns: 15rem minmax(0, 46rem); justify-content: center; align-items: start; }
  .blog-toc { position: sticky; top: 1rem; max-height: calc(100vh - 2rem); overflow-y: auto; border-width: 0; border-inline-start-width: 2px; border-radius: 0; background: none; padding-block: 0; }
}

.blog-body > p:first-child { margin-block-start: 0; font-size: 1.15rem; }
.blog-body h2 { margin: 3rem 0 1rem; font-size: clamp(1.45rem, 3vw, 1.75rem); scroll-margin-top: 1rem; }
.blog-body h3 { margin: 1.5rem 0 0.5rem; font-size: 1.15rem; }
.blog-body li { margin-block-end: 0.4rem; }
.blog-body ul, .blog-body ol { padding-inline-start: 1.4rem; }
.blog-body li::marker { color: #ff7a2e; }
.blog-body strong { color: #fff; }
.blog-body blockquote { margin: 1.5rem 0; padding: 0.25rem 1.25rem; border-inline-start: 3px solid #ff5c00; border-radius: 0.5rem; background: rgba(255, 92, 0, 0.09); font-size: 0.975rem; }

.blog-blocks { display: grid; gap: 1rem; }
.blog-block { padding: 0.25rem 1.25rem; border: 1px solid rgba(255, 255, 255, 0.11); border-radius: 1rem; background: rgba(255, 255, 255, 0.04); }
.blog-block h3 { margin-block-start: 1rem; }

/* problem and answer pairs */
.blog-section--problems .blog-block { border-inline-start: 3px solid #ff5c00; }
.blog-section--problems .blog-block h3 { color: #ffc39a; }

/* who gets what */
.blog-section--cards .blog-block ul { padding-inline-start: 1.1rem; }

/* values: a list shown as tiles */
.blog-section--values ul { display: grid; gap: 0.75rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); padding: 0; list-style: none; }
.blog-section--values li { margin: 0; padding: 1rem 1.15rem; border-radius: 1rem; background: linear-gradient(140deg, rgba(110, 66, 190, 0.32), rgba(255, 92, 0, 0.12)); }
.blog-section--values li strong { display: block; margin-block-end: 0.25rem; font-size: 1.05rem; }

/* before and now */
.blog-body table { width: 100%; border-collapse: separate; border-spacing: 0; border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 1rem; overflow: hidden; font-size: 0.95rem; line-height: 1.55; }
.blog-body th, .blog-body td { padding: 0.75rem 0.9rem; border-bottom: 1px solid rgba(255, 255, 255, 0.1); text-align: start; vertical-align: top; }
.blog-body thead th { background: rgba(255, 92, 0, 0.2); color: #fff; }
.blog-body tbody th { color: #fff; width: 26%; }
.blog-body tbody tr:last-child > * { border-bottom: 0; }
.blog-body td:last-child { background: rgba(255, 92, 0, 0.07); }
@media (max-width: 40rem) {
  .blog-body thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .blog-body table, .blog-body tbody, .blog-body tr, .blog-body tbody th, .blog-body td { display: block; width: auto; }
  .blog-body tbody th, .blog-body td { border-bottom: 0; padding-block: 0.4rem; }
  .blog-body tbody th { padding-block-start: 0.9rem; font-size: 1.05rem; }
  .blog-body tr { border-bottom: 1px solid rgba(255, 255, 255, 0.14); padding-block-end: 0.6rem; }
  .blog-body tbody tr:last-child { border-bottom: 0; }
  .blog-body td::before { content: attr(data-label); display: block; color: #ffb27a; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
}

.blog-section--faq .blog-block h3 { font-size: 1.05rem; }
.blog-section--limits { margin-block-start: 3rem; padding: 0.25rem 1.25rem; border: 1px dashed rgba(255, 255, 255, 0.28); border-radius: 1rem; font-size: 0.975rem; }
.blog-section--limits h2 { margin-block-start: 1rem; }
.blog-section--join { margin-block-start: 3rem; padding: 0.25rem 1.5rem 0.5rem; border-radius: 1.25rem; background: linear-gradient(135deg, rgba(255, 92, 0, 0.28), rgba(110, 66, 190, 0.35)); }
.blog-section--join h2 { margin-block-start: 1.25rem; }

.blog-cta { margin-block-start: 3rem; padding: 1.5rem; border: 1px solid rgba(255, 92, 0, 0.45); border-radius: 1.25rem; background: rgba(255, 92, 0, 0.08); }
.blog-cta h2 { margin: 0 0 0.5rem; font-size: 1.3rem; }
.blog-cta p { margin: 0 0 1rem; }
.blog-cta div { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.blog-btn { display: inline-block; padding: 0.6rem 1.25rem; border: 1px solid #ff5c00; border-radius: 999px; background: #ff5c00; color: #1a0838; font-weight: 700; text-decoration: none; }
.blog-btn--ghost { background: transparent; color: #fff; }

.blog-more__title { font-size: 1.4rem; }

.blog-footer { border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 0.875rem; }
.blog-footer__row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem; padding-block: 1.5rem; }
.blog-footer nav { display: flex; flex-wrap: wrap; gap: 1.25rem; }

/* ---- Urdu: self-hosted Nastaliq (fonts-urdu.css); tall letterforms need generous line spacing */
html[lang='ur'] body, html[lang='ur'] :is(h1, h2, h3), .blog-langs a:lang(ur) { font-family: 'Noto Nastaliq Urdu', 'Inter', serif; }
html[lang='ur'] body { line-height: 2.3; }
html[lang='ur'] :is(h1, h2, h3) { line-height: 1.9; }
html[lang='ur'] .blog-hero h1 { font-size: clamp(1.7rem, 4vw, 2.5rem); }
.blog-toc { scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.25) transparent; }
/* the other languages show only the word "اردو" in Urdu: use the tiny subset font, not the full one */
html:not([lang='ur']) .blog-langs a:lang(ur) { font-family: 'Noto Nastaliq Urdu Label', 'Noto Nastaliq Urdu', serif; }

/* ---- Arabic and Chinese: the device's own fonts */
html[lang='ar'] body, html[lang='ar'] :is(h1, h2, h3) { font-family: 'Segoe UI', Tahoma, 'Noto Naskh Arabic', 'Geeza Pro', sans-serif; }
html[lang='ar'] body { line-height: 1.95; }
html[lang='zh-Hans'] body, html[lang='zh-Hans'] :is(h1, h2, h3) { font-family: 'Inter', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', sans-serif; line-break: strict; }
html[lang='zh-Hans'] :is(h1, h2, h3) { line-height: 1.4; }
