/*
Theme Name: Aswat
Theme URI: https://aswateg.com/
Author: Aswat
Description: Lightweight, responsive RTL theme for أصوات (Aswat). Rebuilt from the original Framer landing page with built-in SEO, Open Graph / X link previews and favicons.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: aswat
Tags: rtl-language-support, one-column, custom-logo, theme-options
*/

/* ---------- Fonts ---------- */
@font-face {
	font-family: "Aswat Display";
	src: url("assets/fonts/superx-serif-display-bold.woff2") format("woff2");
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Aswat Display";
	src: url("assets/fonts/superx-serif-display-black.woff2") format("woff2");
	font-weight: 900;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Aswat Text";
	src: url("assets/fonts/superx-sans-text-regular.woff2") format("woff2");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
	--aswat-bg: #dbcfc4;
	--aswat-ink: #0f2240;
	--aswat-red: #c84c40;
	--aswat-gutter: clamp(1rem, 4vw, 2.5rem);
	--aswat-measure: 62rem;
	--aswat-font-display: "Aswat Display", "Noto Kufi Arabic", "Segoe UI", Tahoma, serif;
	--aswat-font-text: "Aswat Text", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	background: var(--aswat-bg);
}

/* Never allow sideways scrolling: this was the cause of the white side area on the old site. */
html,
body {
	max-width: 100%;
	overflow-x: clip;
}

body {
	margin: 0;
	min-height: 100vh;
	min-height: 100dvh;
	display: flex;
	flex-direction: column;
	background: var(--aswat-bg);
	color: var(--aswat-ink);
	font-family: var(--aswat-font-text);
	font-size: clamp(1.0625rem, 0.92rem + 0.6vw, 1.625rem);
	line-height: 1.6;
	direction: rtl;
	text-rendering: optimizeLegibility;
	-webkit-font-smoothing: antialiased;
}

img,
svg,
video {
	display: block;
	max-width: 100%;
	height: auto;
}

a {
	color: inherit;
}

a:focus-visible {
	outline: 3px solid var(--aswat-red);
	outline-offset: 4px;
	border-radius: 6px;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed !important;
	top: 1rem;
	right: 1rem;
	z-index: 100;
	width: auto;
	height: auto;
	padding: 0.75rem 1rem;
	margin: 0;
	clip: auto;
	background: var(--aswat-ink);
	color: #fff;
	font-size: 1rem;
	border-radius: 6px;
}

.site-main {
	flex: 1 0 auto;
}

.container {
	width: 100%;
	max-width: calc(var(--aswat-measure) + 2 * var(--aswat-gutter));
	margin-inline: auto;
	padding-inline: var(--aswat-gutter);
}

/* ---------- Hero ---------- */
.hero {
	position: relative;
	width: 100%;
	margin: 0;
	/* Tall enough on phones to keep the logo readable, wide banner on desktop. */
	height: clamp(15rem, 38vw, 36rem);
	overflow: hidden;
}

/* Image bleeds a few px past each edge and is clipped by the figure, so subpixel rounding can never leave a gap at the sides. */
.hero > picture,
.hero > img {
	position: absolute;
	top: 0;
	left: -4px;
	width: calc(100% + 8px);
	max-width: none;
	height: 100%;
}

.hero img {
	width: 100%;
	max-width: none;
	height: 100%;
	object-fit: cover;
	object-position: 50% 40%;
}

/* Fade into the page colour with an overlay rather than a CSS mask (masks can leave faint 1–2px edges in Safari/Chrome). */
.hero::after {
	content: "";
	position: absolute;
	inset: 0 -4px;
	background: linear-gradient(to bottom, rgba(219, 207, 196, 0) 45%, var(--aswat-bg) 100%);
	pointer-events: none;
}

/* ---------- Intro ---------- */
.intro {
	padding-block: clamp(0.5rem, 2vw, 1.5rem) clamp(2rem, 5vw, 4rem);
}

.intro__title {
	margin: 0 auto clamp(1.75rem, 4vw, 3.5rem);
	max-width: 22ch;
	color: var(--aswat-red);
	font-family: var(--aswat-font-display);
	font-weight: 700;
	font-size: clamp(2rem, 1.1rem + 3.4vw, 3.75rem);
	line-height: 1.15;
	text-align: center;
	text-wrap: balance;
}

.intro__body {
	max-width: var(--aswat-measure);
	margin-inline: auto;
}

.intro__body p {
	margin: 0 0 1em;
	text-align: start;
	text-wrap: pretty;
}

@media (min-width: 640px) {
	.intro__body p {
		text-align: justify;
		text-align-last: start;
	}
}

/* ---------- Social ---------- */
.social {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: clamp(0.5rem, 2vw, 1.25rem);
	margin: 0;
	padding: 0;
	list-style: none;
}

.social a {
	display: grid;
	place-items: center;
	width: clamp(2.75rem, 2.4rem + 1.5vw, 3.5rem);
	height: clamp(2.75rem, 2.4rem + 1.5vw, 3.5rem);
	color: var(--aswat-ink);
	border-radius: 50%;
	transition: color 0.2s ease, transform 0.2s ease;
}

.social a:hover {
	color: var(--aswat-red);
	transform: translateY(-2px);
}

.social svg {
	width: 72%;
	height: 72%;
}

/* ---------- Footer ---------- */
.site-footer {
	padding-block: clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 4vw, 2.5rem);
	text-align: center;
}

.site-footer__copy {
	margin: 1.25rem 0 0;
	font-size: 0.8em;
	opacity: 0.7;
}

/* ---------- Generic pages / posts (for future content) ---------- */
.site-header {
	padding-block: 1.25rem;
}

.site-header .container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}

.site-branding a {
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	color: var(--aswat-red);
	font-family: var(--aswat-font-display);
	font-weight: 700;
	font-size: 1.75rem;
	text-decoration: none;
}

.site-branding img {
	width: 3rem;
	height: 3rem;
	border-radius: 8px;
}

.site-header nav ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 1rem;
}

.site-header nav a {
	text-decoration: none;
}

.site-header nav a:hover,
.site-header nav .current-menu-item > a {
	color: var(--aswat-red);
}

.entry {
	padding-block: clamp(1.5rem, 4vw, 3rem);
}

.entry + .entry {
	border-top: 1px solid rgba(15, 34, 64, 0.15);
}

.entry__title {
	margin: 0 0 1rem;
	color: var(--aswat-red);
	font-family: var(--aswat-font-display);
	font-weight: 700;
	font-size: clamp(1.75rem, 1.2rem + 2vw, 3rem);
	line-height: 1.2;
}

.entry__title a {
	text-decoration: none;
}

.entry__meta {
	margin: 0 0 1.5rem;
	font-size: 0.8em;
	opacity: 0.75;
}

.entry__thumb {
	margin: 0 0 1.5rem;
}

.entry__thumb img {
	width: 100%;
	border-radius: 12px;
}

.entry__content > * {
	max-width: 100%;
}

.entry__content img,
.entry__content iframe {
	max-width: 100%;
	height: auto;
}

.entry__content a {
	color: var(--aswat-red);
}

.pagination {
	display: flex;
	justify-content: center;
	gap: 1rem;
	padding-block: 2rem;
}

.alignwide,
.alignfull {
	max-width: 100%;
}
