/* ==========================================================================
   تُس تُس — ستايل الموقع العام (صفحة الهبوط)
   --------------------------------------------------------------------------
   مكتوب من الصفر. لا bootstrap ولا main.css ولا owl/swiper — ولهذا لا حاجة
   لأي !important ولا لحروب أولوية، ويبقى التصميم هادئًا ومتحكَّمًا به.

   المبدأ: مساحة بيضاء سخيّة، لون واحد مسيطر، تدرّج طباعي واضح، حركة شبه معدومة.
   ========================================================================== */

@font-face {
    font-family: 'HacenLiner';
    src: url('/public/assets/tostos-brand/fonts/HacenLiner.ttf') format('truetype');
    font-display: swap;
}

:root {
    --primary: #36788d;
    --secondary: #05485d;
    --accent: #46b3ad;
    --tint: #cdefed;

    --ink: #0f2f3b;
    --muted: #5f7d89;
    --line: #e4eff0;
    --wash: #f6fbfb;
    --white: #fff;

    --wrap: 1140px;
    --r: 14px;
    --shadow: 0 1px 2px rgba(5, 72, 93, .04), 0 10px 30px rgba(5, 72, 93, .06);
    --ease: cubic-bezier(.22, .61, .36, 1);
}

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

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

body {
    margin: 0;
    font-family: 'HacenLiner', system-ui, -apple-system, 'Segoe UI', sans-serif;
    color: var(--ink);
    background: var(--white);
    line-height: 1.75;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { margin: 0 0 .5rem; line-height: 1.3; font-weight: 700; color: var(--secondary); }
p { margin: 0 0 1rem; }

.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.muted { color: var(--muted); }
.center { text-align: center; }

.skip-link {
    position: absolute; inset-inline-start: -9999px; top: 0; z-index: 100;
    background: var(--secondary); color: #fff; padding: .7rem 1.1rem; border-radius: 0 0 var(--r) 0;
}
.skip-link:focus { inset-inline-start: 0; }

:where(a, button):focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

/* ------------------------------- أزرار ------------------------------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: .8rem 1.6rem; border-radius: 999px;
    font-weight: 700; font-size: .95rem; border: 1px solid transparent;
    cursor: pointer; transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
    white-space: nowrap;
}
.btn-sm { padding: .55rem 1.1rem; font-size: .875rem; }

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--secondary); }

.btn-ghost { background: transparent; color: var(--secondary); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

.btn-onDark { background: #fff; color: var(--secondary); }
.btn-onDark:hover { background: var(--tint); }

/* ------------------------------ الترويسة ------------------------------ */

.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(140%) blur(8px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: 0 4px 20px rgba(5, 72, 93, .05); }

.header-inner { display: flex; align-items: center; gap: 1.5rem; min-height: 72px; }
.brand img { width: 132px; height: auto; }

.nav { display: flex; gap: 1.75rem; margin-inline-start: auto; font-size: .95rem; }
.nav a { color: var(--ink); padding: .25rem 0; border-bottom: 2px solid transparent; transition: color .2s var(--ease), border-color .2s var(--ease); }
.nav a:hover { color: var(--primary); border-bottom-color: var(--accent); }

.header-actions { display: flex; align-items: center; gap: .75rem; }

.nav-toggle {
    display: none; width: 42px; height: 42px; border: 1px solid var(--line);
    background: #fff; border-radius: 10px; padding: 0; cursor: pointer;
    flex-direction: column; align-items: center; justify-content: center; gap: 4px;
}
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--secondary); border-radius: 2px; }

/* ------------------------------ الهيرو ------------------------------ */

.hero {
    background: linear-gradient(180deg, var(--wash) 0%, #fff 100%);
    border-bottom: 1px solid var(--line);
}
.hero-inner { padding: clamp(3.5rem, 9vw, 6.5rem) 0; max-width: 46rem; }

.eyebrow {
    color: var(--accent); font-weight: 700; font-size: .875rem;
    letter-spacing: .04em; margin-bottom: .75rem;
}
.hero h1 { font-size: clamp(1.9rem, 1.2rem + 3vw, 3.1rem); margin-bottom: 1rem; }
.lede { color: var(--muted); font-size: clamp(1rem, .96rem + .3vw, 1.15rem); }
.hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

/* ------------------------------ الأرقام ------------------------------ */

.stats { border-bottom: 1px solid var(--line); background: #fff; }
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    padding: clamp(1.75rem, 4vw, 2.75rem) 0;
    text-align: center; gap: 1rem;
}
.stat { display: flex; flex-direction: column; gap: .15rem; }
.stat .num { font-size: clamp(1.4rem, 1rem + 1.6vw, 2.1rem); font-weight: 700; color: var(--primary); line-height: 1.2; }
.stat .lbl { color: var(--muted); font-size: .875rem; }

/* ------------------------------ الأقسام ------------------------------ */

.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.section.alt { background: var(--wash); }

.section-head { max-width: 42rem; margin: 0 auto clamp(2rem, 4vw, 3rem); text-align: center; }
.section-head h2 { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.1rem); }
.section-head p { color: var(--muted); margin: 0; }

/* بطاقات الفئات */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }

.card {
    background: #fff; border: 1px solid var(--line); border-radius: var(--r);
    padding: 1.25rem; text-align: center;
    transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.card:hover { border-color: var(--accent); box-shadow: var(--shadow); }

.card-media {
    width: 76px; height: 76px; margin: 0 auto .9rem;
    border-radius: 16px; overflow: hidden; background: var(--wash);
    display: grid; place-items: center;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card h3 { font-size: 1rem; margin-bottom: .15rem; }
.card .muted { font-size: .8125rem; margin: 0; }

/* كيف يعمل */
.steps {
    list-style: none; margin: 0; padding: 0;
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem;
    counter-reset: step;
}
.steps li { text-align: center; }
.step-n {
    display: grid; place-items: center;
    width: 46px; height: 46px; margin: 0 auto .85rem;
    border-radius: 50%; background: var(--tint); color: var(--secondary);
    font-weight: 700; font-size: 1.05rem;
}
.steps h3 { font-size: 1rem; }
.steps p { color: var(--muted); font-size: .9rem; margin: 0; }

/* من نحن */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.about-media img { border-radius: var(--r); box-shadow: var(--shadow); width: 100%; }

.link-arrow { color: var(--primary); font-weight: 700; display: inline-flex; gap: .4rem; transition: gap .2s var(--ease); }
.link-arrow::after { content: "←"; }
[dir="ltr"] .link-arrow::after { content: "→"; }
.link-arrow:hover { gap: .75rem; }

/* ---------------------- شريط دعوة مزوّدي الخدمة ---------------------- */

.band { background: linear-gradient(135deg, var(--secondary) 0%, #0a5f78 60%, var(--primary) 100%); color: #fff; }
.band-inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 2rem; padding: clamp(2.5rem, 6vw, 4rem) 0; flex-wrap: wrap;
}
.band h2 { color: #fff; margin-bottom: .35rem; font-size: clamp(1.35rem, 1.1rem + 1.2vw, 1.9rem); }
.band p { color: var(--tint); margin: 0; }

/* ------------------------------ التذييل ------------------------------ */

.site-footer { background: var(--secondary); color: var(--tint); padding-top: clamp(2.5rem, 6vw, 4rem); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; padding-bottom: 2.5rem; }
.site-footer h4 { color: #fff; font-size: .95rem; margin-bottom: .9rem; }
.site-footer a { display: block; color: var(--tint); padding: .2rem 0; font-size: .9rem; transition: color .2s var(--ease); }
.site-footer a:hover { color: #fff; }
.footer-brand img { width: 140px; margin-bottom: .9rem; }
.footer-brand .muted { color: rgba(205, 239, 237, .7); font-size: .875rem; }

.social { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: .75rem; }
.social a { display: inline-block; font-size: .85rem; border: 1px solid rgba(255, 255, 255, .2); padding: .3rem .8rem; border-radius: 999px; }

.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); padding: 1.25rem 0; }
.footer-bottom p { margin: 0; font-size: .85rem; color: rgba(205, 239, 237, .75); text-align: center; }

/* ------------------------------ التجاوب ------------------------------ */

@media (max-width: 980px) {
    .cards { grid-template-columns: repeat(3, 1fr); }
    .steps { grid-template-columns: repeat(2, 1fr); }
    .about-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
    .nav-toggle { display: flex; }
    .nav {
        display: none; position: absolute; inset-inline: 0; top: 100%;
        flex-direction: column; gap: 0; background: #fff;
        border-block: 1px solid var(--line); padding: .5rem 1.25rem 1rem;
        box-shadow: 0 12px 24px rgba(5, 72, 93, .08);
    }
    .nav.open { display: flex; }
    .nav a { padding: .7rem 0; border-bottom: 1px solid var(--line); }
    .nav a:last-child { border-bottom: 0; }
    .site-header { position: relative; }
    .header-inner { position: relative; }
    .header-actions { margin-inline-start: auto; }

    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem 1rem; }
    .cards { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
    .band-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 420px) {
    .header-actions .btn { display: none; }
    .cards { grid-template-columns: 1fr; }
    .steps { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
}

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

/* بديل أنيق حين لا توجد صورة فئة حقيقية (كل الفئات تشير حاليًا إلى def.png النائبة) */
.card-media.is-initial {
    background: linear-gradient(160deg, var(--tint), #e8f6f5);
    color: var(--primary);
    font-size: 1.9rem;
    font-weight: 700;
    line-height: 1;
}
