/* Shafagh — Persian-first, full-width, intentionally minimal. */
:root {
  --shafagh-page-padding: clamp(16px, 2.5vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { direction: rtl; }
body {
  margin: 0;
  direction: rtl;
  text-align: right;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }

.wp-site-blocks,
.shafagh-main,
.shafagh-header,
.shafagh-footer,
.shafagh-wide {
  width: 100%;
  max-width: none;
}

.wp-site-blocks { min-height: 100vh; }
.shafagh-main {
  margin: 0;
  padding: var(--shafagh-page-padding);
}

/* In Shafagh, normal/wide/full blocks all remain genuinely wide by default. */
.shafagh-main > :where(:not(.alignleft):not(.alignright):not(.alignfull)),
.shafagh-main .wp-block-post-content > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
  max-width: none;
  margin-left: 0;
  margin-right: 0;
}

.alignwide,
.alignfull {
  width: 100%;
  max-width: none;
  margin-left: 0;
  margin-right: 0;
}

.shafagh-header,
.shafagh-footer {
  padding: 16px var(--shafagh-page-padding);
}

.shafagh-header-inner,
.shafagh-footer-inner {
  width: 100%;
  max-width: none;
}

.shafagh-header .wp-block-site-title a,
.shafagh-header .wp-block-site-logo a,
.wp-block-post-title a {
  color: inherit;
  text-decoration: none;
}

.shafagh-copyright { margin: 0; }

pre, code, kbd, samp { direction: ltr; text-align: left; }
pre { overflow-x: auto; }

input, textarea, select, button { font: inherit; }
input[type="text"], input[type="email"], input[type="url"], input[type="search"], input[type="password"], textarea, select {
  max-width: 100%;
}

@media (max-width: 782px) {
  :root { --shafagh-page-padding: 16px; }
}
