/*
Theme Name: SUSTELEMENTS
Theme URI: https://sustelements.com
Author: SUSTELEMENTS Environmental & Industrial Consultancy
Author URI: https://sustelements.com
Description: Custom WordPress theme for عناصر الاستدامة للاستشارات البيئية والصناعية (SUSTELEMENTS), converted from a static Lovable export. Provides industrial licensing, environmental permitting, and MODON industrial-land consultancy pages with full RTL Arabic support and an English page.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: sustelements
Tags: custom-background, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, right-to-left-language-support

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned.

The bulk of this theme's visual styling lives in /assets/css/main.css
(enqueued via functions.php) — it is the original compiled utility
stylesheet from the site export, kept intact to preserve the exact
design. This file only carries the required WordPress theme header
above plus a few small additions needed for WordPress-specific markup
(the mobile navigation drawer and default block editor content) that
did not exist in the original static export.
*/

/* ==========================================================================
   Mobile navigation drawer
   (New markup added for a working mobile menu — the static export shipped
   a menu button with no corresponding panel, so this reproduces the same
   visual language used across the rest of the site.)
   ========================================================================== */

#mobile-nav {
	display: none;
	border-bottom: 1px solid var(--border, #e5e7eb);
	background-color: var(--background, #fff);
}

#mobile-nav.is-open {
	display: block;
}

#mobile-nav .container-page {
	padding-top: 0.75rem;
	padding-bottom: 1rem;
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
}

#mobile-nav .mobile-nav-actions {
	margin-top: 0.5rem;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	border-top: 1px solid var(--border, #e5e7eb);
	padding-top: 0.75rem;
}

@media (min-width: 1024px) {
	#mobile-nav {
		display: none !important;
	}
}

/* ==========================================================================
   Default WordPress content fallbacks
   (Applied only if editable WP content — e.g. widget areas, block content
   inside page.php — is used; does not affect the converted static pages.)
   ========================================================================== */

.sustelements-content img {
	max-width: 100%;
	height: auto;
}

.screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute !important;
	width: 1px;
	word-wrap: normal !important;
}


/* ==========================================================================
   Desktop header visibility fix
   Ensures the desktop navigation/actions and mobile menu button switch
   correctly at desktop widths even if another stylesheet overrides the
   utility classes.
   ========================================================================== */
@media (min-width: 1024px) {
	header > .container-page > nav[aria-label="التنقل الرئيسي"] {
		display: flex !important;
	}

	header > .container-page > div > button[data-menu-toggle] {
		display: none !important;
	}

	header > #mobile-nav {
		display: none !important;
	}

	header > .container-page > div > a[href^="tel:"] {
		display: inline-flex !important;
	}

	header > .container-page > div > a[href^="https://wa.me/"] {
		display: inline-flex !important;
	}
}

@media (max-width: 1023px) {
	header > .container-page > nav[aria-label="التنقل الرئيسي"] {
		display: none !important;
	}

	header > .container-page > div > button[data-menu-toggle] {
		display: grid !important;
	}
}
