/* ==========================================================
   ebmnt1-base.css
   الخط + متغيرات التخطيط + reset + هيكل الصفحة والسيكشن
   Breakpoints (mobile first): 320 / 375 / 425 / 768 / 1024 / 1440
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=El+Messiri:wght@400..700&display=swap');

:root {
    /* layout */
    --ebmnt1-layout-max-width: 75rem;
    --ebmnt1-layout-narrow-max-width: 56rem;
    --ebmnt1-layout-gutter: 2em;
    --ebmnt1-layout-main-gap: 5em;
    --ebmnt1-layout-section-gap: 2em;
    --ebmnt1-layout-header-height: 4.5rem;

    /* page colors */
    --ebmnt1-base-body-background: var(--ebmnt1-color-page-background);
    --ebmnt1-base-body-text-color: var(--ebmnt1-color-text);
    --ebmnt1-base-heading-color: var(--ebmnt1-color-helper-purple);
    --ebmnt1-base-focus-outline-color: var(--ebmnt1-color-primary);
    --ebmnt1-base-selection-background: var(--ebmnt1-color-helper-pink-soft);
    --ebmnt1-base-selection-text-color: var(--ebmnt1-color-helper-purple-deep);

    /* typography */
    --ebmnt1-base-font-family: "El Messiri", sans-serif;
    --ebmnt1-base-font-size-body: clamp(0.95rem, 0.9rem + 0.25vw, 1.1rem);
    --ebmnt1-base-font-size-section-title: clamp(1.7rem, 1.2rem + 2.6vw, 3rem);
    --ebmnt1-base-font-size-section-subtitle: clamp(1rem, 0.92rem + 0.4vw, 1.2rem);
    --ebmnt1-base-line-height: 1.8;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: "El Messiri", sans-serif;
    font-size: var(--ebmnt1-base-font-size-body);
    line-height: var(--ebmnt1-base-line-height);
    color: var(--ebmnt1-base-body-text-color);
    background-color: var(--ebmnt1-base-body-background);
    direction: rtl;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

body.ebmnt1-no-scroll {
    overflow: hidden;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

ul,
ol {
    list-style: none;
}

button,
input,
textarea,
select {
    font: inherit;
    color: inherit;
}

button {
    background: none;
    border: 0;
    cursor: pointer;
}

h1,
h2,
h3,
h4 {
    color: var(--ebmnt1-base-heading-color);
    line-height: 1.35;
}

::selection {
    background-color: var(--ebmnt1-base-selection-background);
    color: var(--ebmnt1-base-selection-text-color);
}

:focus-visible {
    outline: 3px solid var(--ebmnt1-base-focus-outline-color);
    outline-offset: 3px;
}

/* ---------- هيكل الصفحة: header => main => footer ---------- */

main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--ebmnt1-layout-main-gap);
    flex: 1;
    width: 100%;
}

/* ---------- master + inner container ---------- */

.ebmnt1-section {
    width: 100%;
    display: flex;
    flex-direction: column;
}

.ebmnt1-section__inner {
    width: calc(100% - var(--ebmnt1-layout-gutter));
    max-width: var(--ebmnt1-layout-max-width);
    margin-inline: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--ebmnt1-layout-section-gap);
    text-align: center;
}

/* سيكشن بخلفية ملونة: مسافة أعلى/أسفل عن طريق gap + عناصر pseudo فارغة (بدون padding/margin) */
.ebmnt1-section--spaced {
    gap: 3em;
}

.ebmnt1-section--spaced::before,
.ebmnt1-section--spaced::after {
    content: "";
}

/* ---------- عنوان سيكشن مشترك ---------- */

.ebmnt1-section-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6em;
}

.ebmnt1-section-head__title {
    font-size: var(--ebmnt1-base-font-size-section-title);
    font-weight: 700;
}

.ebmnt1-section-head__subtitle {
    font-size: var(--ebmnt1-base-font-size-section-subtitle);
    max-width: 40rem;
    color: var(--ebmnt1-color-text-soft);
}

/* ---------- حركة الظهور عند التمرير ---------- */

.ebmnt1-reveal {
    opacity: 0;
    transform: translateY(1.8rem) scale(0.98);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
    transition-delay: var(--ebmnt1-reveal-delay, 0s);
}

.ebmnt1-reveal.ebmnt1-is-visible {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .ebmnt1-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ---------- breakpoints ---------- */

@media (min-width: 768px) {
    :root {
        --ebmnt1-layout-gutter: 3em;
        --ebmnt1-layout-section-gap: 2.5em;
    }
}

@media (min-width: 1024px) {
    :root {
        --ebmnt1-layout-gutter: 4em;
        --ebmnt1-layout-main-gap: 6em;
    }
}

@media (min-width: 1440px) {
    :root {
        --ebmnt1-layout-max-width: 82rem;
    }
}
