/*
Theme Name: WParaby
Theme URI: https://wparaby.com
Author: WParaby
Author URI: https://wparaby.com
Description: Lightweight Arabic-first block theme for WParaby kits. Defines the WParaby design tokens and default templates; all features live in the WParaby plugin.
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wparaby-theme
Tags: rtl-language-support, full-site-editing, block-patterns, wide-blocks
*/

/* Only what theme.json cannot express. Logical properties keep RTL and LTR correct. */

:where(.wp-block-quote) {
	border-inline-start: 4px solid var(--wp--preset--color--primary);
	padding-inline-start: var(--wp--preset--spacing--30);
	margin-inline: 0;
}

:where(.wp-block-quote.has-text-align-center) {
	border-inline-start: 0;
	padding-inline-start: 0;
}

:where(.wp-block-pullquote) {
	border-block: 2px solid var(--wp--preset--color--border);
}

:where(.wp-block-code, pre) {
	direction: ltr;
	text-align: left;
	background: var(--wp--preset--color--base-2);
	border-radius: var(--wp--custom--radius--sm);
	padding: var(--wp--preset--spacing--20);
	overflow-x: auto;
}

:where(input, textarea, select) {
	font: inherit;
}

:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}

.screen-reader-text:focus {
	clip-path: none;
	inset-inline-start: 0.5rem;
	top: 0.5rem;
	padding: 0.75rem 1rem;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--contrast);
	z-index: 100000;
}

/* Sticky header option: add the "is-sticky" class to the header template part. */
.is-sticky {
	position: sticky;
	top: 0;
	z-index: 50;
}

.admin-bar .is-sticky {
	top: var(--wp-admin--admin-bar--height, 32px);
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/*
 * Kit pages and templates are stacks of full-width sections that carry their
 * own padding: no block gap between header, sections and footer (the
 * Elementor version of a kit has none either).
 */
.wp-site-blocks:has(> .wpa-kit-main, > .woocommerce > .wpa-kit-main, > .wpa-location, > .elementor-location-header, > .elementor-location-footer) > * + *,
.wpa-kit-main > .alignfull,
.wpa-kit-main > .alignfull + *,
.wpa-kit-main > .wp-block-post-content > .alignfull,
.wpa-kit-main > .wp-block-post-content > .alignfull + * {
	margin-block-start: 0;
}

/*
 * A column's width includes its padding (55% means 55% of the row), as in
 * the Elementor version of the same section.
 */
.wp-block-column {
	box-sizing: border-box;
}
