/* =========================
   عِشرة | Eshra — Main Stylesheet
   منصة الزواج الجاد
========================= */

/* =========================
   ROOT VARIABLES
========================= */
:root {
    /* الألوان الأساسية */
    --primary: #1c5c66;
    --primary-dark: #123f47;
    --primary-light: #2f7a86;
    --primary-tint: #e6eeee;
    --secondary: #4a6b63;
    --accent: #c9a24b;
    --accent-dark: #a8842f;
    --accent-tint: #f6ecd3;
    --background: #faf8f3;
    --surface: #ffffff;
    --surface-alt: #f3f0e8;
    --text: #1f2b2c;
    --text-muted: #6f8386;
    --text-on-primary: #f7f5ee;
    --border: #e3e0d5;
    --border-strong: #cdd3ce;
    --success: #2e7d4f;
    --danger: #a53d3d;
    /* الطباعة */
    --font-display: 'Cairo', sans-serif;
    --font-body: 'Tajawal', sans-serif;
    /* القياسات */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 22px;
    --radius-pill: 999px;
    --shadow-sm: 0 2px 10px rgba(28, 41, 43, 0.06);
    --shadow-md: 0 10px 30px rgba(28, 41, 43, 0.08);
    --shadow-lg: 0 20px 50px rgba(28, 41, 43, 0.12);
    --container-max: 1200px;
    --nav-height: 78px;
}

/* =========================
   RESET
========================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--background);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
    direction: rtl;
}

img {
    max-width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

ul {
    list-style: none;
}

input, select, textarea {
    font-family: inherit;
    width: 100%;
}

:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.001ms !important;
        transition-duration: 0.001ms !important;
    }
}

/* =========================
   GLOBAL
========================= */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--text);
    line-height: 1.35;
}

.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 90px 0;
}

.section-alt {
    background-color: var(--surface-alt);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent-dark);
    background: var(--accent-tint);
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    margin-bottom: 18px;
    letter-spacing: 0.3px;
}

.section-title {
    font-size: clamp(1.7rem, 3vw, 2.4rem);
    margin-bottom: 14px;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 620px;
}

.section-head {
    margin-bottom: 48px;
}

    .section-head.center {
        text-align: center;
        margin-inline: auto;
    }

        .section-head.center .section-subtitle {
            margin-inline: auto;
        }

/* رمز التداخل — إشارة العلامة (حلقتان متشابكتان ترمزان للعِشرة) */
.eshra-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex-shrink: 0;
}

    .eshra-mark svg {
        width: 100%;
        height: 100%;
    }

.eshra-mark--lg {
    width: 68px;
    height: 68px;
}

/* أزرار */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.98rem;
    padding: 14px 30px;
    border-radius: var(--radius-pill);
    transition: all 0.25s ease;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary);
    color: var(--text-on-primary);
    box-shadow: var(--shadow-sm);
}

    .btn-primary:hover {
        background: var(--primary-dark);
        transform: translateY(-2px);
        box-shadow: var(--shadow-md);
    }

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}

    .btn-outline:hover {
        background: var(--primary);
        color: var(--text-on-primary);
    }

.btn-gold {
    background: var(--accent);
    color: #302209;
}

    .btn-gold:hover {
        background: var(--accent-dark);
        transform: translateY(-2px);
    }

.btn-ghost {
    background: transparent;
    color: var(--text);
}

    .btn-ghost:hover {
        color: var(--primary);
    }

.btn-sm {
    padding: 9px 20px;
    font-size: 0.85rem;
}

.btn-block {
    width: 100%;
}

.btn-danger-outline {
    background: transparent;
    color: var(--danger);
    border: 1.5px solid var(--danger);
}

    .btn-danger-outline:hover {
        background: var(--danger);
        color: #fff;
    }

/* =========================
   NAVBAR
========================= */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--nav-height);
    display: flex;
    align-items: center;
    background: rgba(250, 248, 243, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    transition: box-shadow 0.3s ease, background 0.3s ease;
}

    .navbar.is-scrolled {
        box-shadow: var(--shadow-sm);
        background: rgba(250, 248, 243, 0.98);
    }

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-text {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--primary-dark);
}

    .brand-text span {
        color: var(--accent-dark);
        font-weight: 500;
        font-size: 0.95rem;
    }

.nav-links {
    display: flex;
    align-items: center;
    gap: 34px;
}

    .nav-links a {
        font-weight: 600;
        color: var(--text);
        position: relative;
        padding: 6px 0;
        transition: color 0.2s ease;
    }

        .nav-links a::after {
            content: '';
            position: absolute;
            right: 0;
            bottom: -3px;
            width: 0;
            height: 2px;
            background: var(--accent);
            transition: width 0.25s ease;
        }

        .nav-links a:hover,
        .nav-links a.active {
            color: var(--primary);
        }

            .nav-links a:hover::after,
            .nav-links a.active::after {
                width: 100%;
            }

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
}

    .nav-toggle span {
        width: 24px;
        height: 2.5px;
        background: var(--primary-dark);
        border-radius: 2px;
        transition: all 0.3s ease;
    }

    .nav-toggle.is-open span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .nav-toggle.is-open span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.is-open span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

.mobile-menu {
    position: fixed;
    inset: var(--nav-height) 0 0 0;
    background: var(--background);
    z-index: 999;
    padding: 30px 24px;
    display: flex;
    flex-direction: column;
    gap: 26px;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.28s ease;
    overflow-y: auto;
}

    .mobile-menu.is-open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .mobile-menu a {
        font-family: var(--font-display);
        font-size: 1.15rem;
        font-weight: 700;
        color: var(--text);
        border-bottom: 1px solid var(--border);
        padding-bottom: 16px;
    }

    .mobile-menu .mobile-actions {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-top: 10px;
    }

/* =========================
   HERO
========================= */
.hero {
    position: relative;
    padding: 70px 0 60px;
    overflow: hidden;
    background: linear-gradient(180deg, var(--primary-tint) 0%, var(--background) 75%);
}

.hero-pattern {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.5;
    pointer-events: none;
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 50px;
    align-items: center;
}

.hero-content .eyebrow {
    background: var(--surface);
}

.hero-title {
    font-size: clamp(2.2rem, 4.2vw, 3.4rem);
    margin-bottom: 20px;
}

    .hero-title .highlight {
        color: var(--primary);
        position: relative;
    }

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 520px;
    margin-bottom: 34px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 34px;
}

.hero-trust {
    display: flex;
    gap: 28px;
    flex-wrap: wrap;
}

.hero-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.92rem;
    color: var(--text-muted);
    font-weight: 600;
}

    .hero-trust-item i {
        color: var(--primary);
    }

.hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-visual-card {
    width: 100%;
    max-width: 420px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background: var(--surface);
    border: 1px solid var(--border);
}

    .hero-visual-card img {
        width: 100%;
        height: 320px;
        object-fit: cover;
    }

.hero-visual-badge {
    position: absolute;
    bottom: -18px;
    right: -10px;
    background: var(--surface);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 240px;
}

    .hero-visual-badge .num {
        font-family: var(--font-display);
        font-weight: 800;
        font-size: 1.4rem;
        color: var(--primary);
    }

    .hero-visual-badge .label {
        font-size: 0.8rem;
        color: var(--text-muted);
        font-weight: 600;
    }

/* =========================
   SEARCH
========================= */
.search-box {
    position: relative;
    z-index: 2;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 30px;
    margin-top: -50px;
    border: 1px solid var(--border);
}

.search-box-title {
    font-size: 1.1rem;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--primary-dark);
}

.search-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    align-items: end;
}

.search-actions-full {
    grid-column: 1 / -1;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .field label {
        font-size: 0.82rem;
        font-weight: 700;
        color: var(--text-muted);
    }

    .field input,
    .field select {
        padding: 12px 14px;
        border: 1.5px solid var(--border);
        border-radius: var(--radius-sm);
        background: var(--surface);
        color: var(--text);
        font-size: 0.95rem;
        transition: border-color 0.2s ease;
    }

        .field input:focus,
        .field select:focus {
            border-color: var(--primary);
        }

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

/* بحث صفحة search.html */
.search-page-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
    align-items: start;
}

.filters-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    position: sticky;
    top: calc(var(--nav-height) + 20px);
}

    .filters-panel h3 {
        font-size: 1.1rem;
        margin-bottom: 20px;
        color: var(--primary-dark);
    }

    .filters-panel .field {
        margin-bottom: 16px;
    }

.results-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 22px;
    flex-wrap: wrap;
    gap: 14px;
}

.results-count {
    color: var(--text-muted);
    font-weight: 600;
}

.results-sort {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .results-sort select {
        padding: 9px 14px;
        border-radius: var(--radius-sm);
        border: 1.5px solid var(--border);
        background: var(--surface);
    }

.mobile-filters-btn {
    display: none;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
}

    .pagination button {
        width: 40px;
        height: 40px;
        border-radius: var(--radius-sm);
        border: 1.5px solid var(--border);
        font-weight: 700;
        color: var(--text);
        background: var(--surface);
        transition: all 0.2s ease;
    }

        .pagination button:hover,
        .pagination button.active {
            background: var(--primary);
            color: var(--text-on-primary);
            border-color: var(--primary);
        }

/* Offcanvas الفلاتر للموبايل */
.offcanvas {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(340px, 90vw);
    background: var(--surface);
    z-index: 1200;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    padding: 24px;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

[dir="rtl"] .offcanvas {
    inset: 0 auto 0 0;
    transform: translateX(-100%);
}

.offcanvas.is-open {
    transform: translateX(0);
}

.offcanvas-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 30, 30, 0.4);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

    .offcanvas-overlay.is-open {
        opacity: 1;
        visibility: visible;
    }

.offcanvas-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* =========================
   PROFILE CARDS
========================= */
.profiles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.profile-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.25s ease;
    position: relative;
}

    .profile-card:hover {
        transform: translateY(-6px);
        box-shadow: var(--shadow-md);
        border-color: var(--border-strong);
    }

.profile-card-media {
    position: relative;
    height: 210px;
    overflow: hidden;
}

    .profile-card-media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.profile-fav-btn {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
}

    .profile-fav-btn:hover,
    .profile-fav-btn.is-active {
        color: #b5384b;
    }

        .profile-fav-btn.is-active i {
            font-weight: 900;
        }

.profile-card-body {
    padding: 20px;
}

.profile-card-name {
    display: flex;
    align-items: baseline;
    gap: 6px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 6px;
}

    .profile-card-name .age {
        color: var(--text-muted);
        font-weight: 500;
        font-size: 0.95rem;
    }

.profile-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

    .profile-card-meta span {
        display: flex;
        align-items: center;
        gap: 5px;
    }

.profile-card-bio {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.profile-card-actions {
    display: flex;
    gap: 10px;
}

    .profile-card-actions .btn {
        flex: 1;
        padding: 10px 12px;
        font-size: 0.85rem;
    }

/* شريط تقدّم بسيط للـ Section الأخير في الصفحة الرئيسية */
.featured-cta {
    text-align: center;
    margin-top: 44px;
}

/* =========================
   HOW IT WORKS / WHY PREVIEW (index.html)
========================= */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.step-card {
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: 30px 24px;
    text-align: center;
    border: 1px solid var(--border);
    position: relative;
}

.step-number {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 0.85rem;
    color: var(--accent-dark);
    background: var(--accent-tint);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.step-card h4 {
    font-size: 1.05rem;
    margin-bottom: 10px;
}

.step-card p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 26px;
}

.why-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.why-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-sm);
    background: var(--primary-tint);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.why-card h4 {
    font-size: 1.02rem;
    margin-bottom: 6px;
}

.why-card p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

.trust-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    background: var(--primary-dark);
    border-radius: var(--radius-lg);
    padding: 46px 40px;
    color: var(--text-on-primary);
}

.trust-strip-item {
    text-align: center;
}

    .trust-strip-item i {
        font-size: 1.6rem;
        color: var(--accent);
        margin-bottom: 12px;
    }

    .trust-strip-item h4 {
        color: var(--text-on-primary);
        font-size: 1rem;
        margin-bottom: 6px;
    }

    .trust-strip-item p {
        font-size: 0.85rem;
        opacity: 0.8;
    }

.cta-band {
    text-align: center;
    background: var(--accent-tint);
    border-radius: var(--radius-lg);
    padding: 60px 30px;
}

    .cta-band h2 {
        margin-bottom: 14px;
    }

    .cta-band p {
        color: var(--text-muted);
        margin-bottom: 30px;
        max-width: 520px;
        margin-inline: auto;
    }

/* =========================
   EMPTY PAGE PLACEHOLDER (about / how-it-works / contact) */
.empty-page {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =========================
   FORMS
========================= */
.auth-wrapper {
    min-height: calc(100vh - var(--nav-height));
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    background: linear-gradient(180deg, var(--primary-tint) 0%, var(--background) 100%);
}

.auth-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 44px;
    width: 100%;
    max-width: 440px;
    border: 1px solid var(--border);
}

.auth-card-head {
    text-align: center;
    margin-bottom: 30px;
}

    .auth-card-head .eshra-mark {
        margin: 0 auto 14px;
    }

    .auth-card-head p {
        color: var(--text-muted);
        font-size: 0.92rem;
    }

.form-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 40px;
    border: 1px solid var(--border);
    max-width: 780px;
    margin: 0 auto;
}

.form-section {
    margin-bottom: 34px;
}

    .form-section:last-child {
        margin-bottom: 0;
    }

.form-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin: 25px 0 20px;
    font-size: 1.1rem;
    color: var(--primary-dark);
    border: none;
    padding: 0;
}

    .form-section-title::after {
        content: "";
        flex: 1;
        height: 2px;
        background: var(--border);
    }

    .form-section-title::before {
        content: none;
    }

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

    .form-grid .field.full {
        grid-column: 1 / -1;
    }

.password-field {
    position: relative;
}

.password-toggle {
    position: absolute;
    left: 14px;
    top: 38px;
    color: var(--text-muted);
}

.field-error {
    font-size: 0.78rem;
    color: var(--danger);
    display: none;
}

.field.has-error input,
.field.has-error select {
    border-color: var(--danger);
}

.field.has-error .field-error {
    display: block;
}

.checkbox-field {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

    .checkbox-field input {
        width: 18px;
        height: 18px;
        margin-top: 3px;
        accent-color: var(--primary);
    }

.form-row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.form-footnote {
    text-align: center;
    margin-top: 22px;
    color: var(--text-muted);
    font-size: 0.92rem;
}

    .form-footnote a {
        color: var(--primary);
        font-weight: 700;
    }

.success-box {
    display: none;
    background: #eaf5ee;
    border: 1.5px solid var(--success);
    color: var(--success);
    border-radius: var(--radius-sm);
    padding: 16px 18px;
    font-weight: 600;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
}

    .success-box.is-visible {
        display: flex;
    }

.upload-box {
    border: 2px dashed var(--border-strong);
    border-radius: var(--radius-md);
    padding: 30px;
    text-align: center;
    color: var(--text-muted);
    cursor: pointer;
    transition: border-color 0.2s ease;
}

    .upload-box:hover {
        border-color: var(--primary);
    }

    .upload-box i {
        font-size: 1.8rem;
        color: var(--primary);
        margin-bottom: 10px;
    }

/* =========================
   PROFILE (single) PAGE
========================= */
.profile-header {
    background: var(--surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    padding: 36px;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.profile-header-photo img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    border-radius: var(--radius-md);
}

.profile-header-info h1 {
    font-size: 1.7rem;
    margin-bottom: 10px;
}

.profile-header-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

    .profile-header-tags span {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 0.9rem;
        color: var(--text-muted);
        background: var(--surface-alt);
        padding: 7px 14px;
        border-radius: var(--radius-pill);
    }

.profile-header-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.profile-body-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 26px;
}

.profile-section-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 26px;
    margin-bottom: 20px;
}

    .profile-section-card h3 {
        font-size: 1.05rem;
        margin-bottom: 14px;
        color: var(--primary-dark);
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .profile-section-card p {
        color: var(--text-muted);
    }

    .profile-section-card ul {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }

        .profile-section-card ul li {
            background: var(--primary-tint);
            color: var(--primary-dark);
            padding: 6px 14px;
            border-radius: var(--radius-pill);
            font-size: 0.85rem;
            font-weight: 600;
        }

.report-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--danger);
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 8px;
}

/* =========================
   DASHBOARD
========================= */
.dashboard-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: calc(100vh - var(--nav-height));
}

.dashboard-sidebar {
    background: var(--primary-dark);
    color: var(--text-on-primary);
    padding: 30px 18px;
}

.dashboard-sidebar-links {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 20px;
}

    .dashboard-sidebar-links a {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 13px 16px;
        border-radius: var(--radius-sm);
        color: rgba(247, 245, 238, 0.8);
        font-weight: 600;
        font-size: 0.95rem;
        transition: all 0.2s ease;
    }

        .dashboard-sidebar-links a i {
            width: 20px;
            text-align: center;
        }

        .dashboard-sidebar-links a:hover,
        .dashboard-sidebar-links a.active {
            background: rgba(247, 245, 238, 0.1);
            color: var(--text-on-primary);
        }

        .dashboard-sidebar-links a.active {
            background: var(--accent);
            color: #302209;
        }

.dashboard-sidebar hr {
    border: none;
    border-top: 1px solid rgba(247, 245, 238, 0.15);
    margin: 16px 0;
}

.dashboard-main {
    padding: 40px;
    background: var(--background);
}

.dashboard-welcome {
    margin-bottom: 30px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-card-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-sm);
    background: var(--primary-tint);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.stat-card-value {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.5rem;
}

.stat-card-label {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.mobile-sidebar-toggle {
    display: none;
}

/* =========================
   MESSAGES
========================= */
.messages-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 640px;
}

.conversations-list {
    border-inline-start: 1px solid var(--border);
    overflow-y: auto;
}

.conversation-item {
    display: flex;
    gap: 12px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s ease;
}

    .conversation-item:hover,
    .conversation-item.active {
        background: var(--primary-tint);
    }

    .conversation-item img {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        object-fit: cover;
    }

.conversation-item-body {
    flex: 1;
    min-width: 0;
}

.conversation-item-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
}

    .conversation-item-top strong {
        font-size: 0.95rem;
    }

    .conversation-item-top span {
        font-size: 0.75rem;
        color: var(--text-muted);
    }

.conversation-item-preview {
    font-size: 0.85rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-panel {
    display: flex;
    flex-direction: column;
}

.chat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

    .chat-header img {
        width: 42px;
        height: 42px;
        border-radius: 50%;
        object-fit: cover;
    }

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.chat-bubble {
    max-width: 65%;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    font-size: 0.92rem;
    line-height: 1.5;
}

    .chat-bubble.received {
        background: var(--surface-alt);
        align-self: flex-start;
        border-bottom-left-radius: 4px;
    }

    .chat-bubble.sent {
        background: var(--primary);
        color: var(--text-on-primary);
        align-self: flex-end;
        border-bottom-right-radius: 4px;
    }

    .chat-bubble .time {
        display: block;
        font-size: 0.7rem;
        opacity: 0.7;
        margin-top: 4px;
    }

.chat-input-area {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid var(--border);
}

    .chat-input-area input {
        flex: 1;
        padding: 12px 16px;
        border-radius: var(--radius-pill);
        border: 1.5px solid var(--border);
        background: var(--surface-alt);
    }

.chat-send-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--text-on-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

    .empty-state i {
        font-size: 2.4rem;
        color: var(--border-strong);
        margin-bottom: 16px;
    }

    .empty-state h3 {
        color: var(--text);
        margin-bottom: 8px;
    }

/* =========================
   NOTIFICATIONS
========================= */
.notification-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    margin-bottom: 12px;
    transition: background 0.2s ease;
}

    .notification-card.unread {
        background: var(--primary-tint);
        border-color: var(--primary-light);
    }

.notification-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--surface-alt);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

    .notification-content .time {
        font-size: 0.78rem;
        color: var(--text-muted);
    }

.notification-mark-btn {
    font-size: 0.78rem;
    color: var(--primary);
    font-weight: 700;
    flex-shrink: 0;
}

/* =========================
   SETTINGS
========================= */
.settings-section {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 26px;
    margin-bottom: 22px;
}

    .settings-section h3 {
        font-size: 1.05rem;
        margin-bottom: 18px;
        color: var(--primary-dark);
    }

.settings-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}

    .settings-row:last-child {
        border-bottom: none;
    }

.settings-row-label strong {
    display: block;
    font-size: 0.95rem;
}

.settings-row-label span {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

    .switch input {
        opacity: 0;
        width: 0;
        height: 0;
    }

.switch-slider {
    position: absolute;
    inset: 0;
    background: var(--border-strong);
    border-radius: var(--radius-pill);
    transition: 0.25s;
    cursor: pointer;
}

    .switch-slider::before {
        content: '';
        position: absolute;
        width: 20px;
        height: 20px;
        right: 3px;
        top: 3px;
        background: #fff;
        border-radius: 50%;
        transition: 0.25s;
    }

.switch input:checked + .switch-slider {
    background: var(--primary);
}

    .switch input:checked + .switch-slider::before {
        transform: translateX(-22px);
    }

.danger-zone {
    border-color: rgba(165, 61, 61, 0.35);
}

/* =========================
   FAQ (Accordion)
========================= */
.accordion-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin-bottom: 14px;
    overflow: hidden;
}

.accordion-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1rem;
    color: var(--text);
}

    .accordion-trigger i {
        color: var(--primary);
        transition: transform 0.25s ease;
    }

.accordion-item.is-open .accordion-trigger i {
    transform: rotate(45deg);
}

.accordion-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.accordion-panel-inner {
    padding: 0 24px 22px;
    color: var(--text-muted);
}

/* =========================
   LEGAL PAGES (terms / privacy)
========================= */
.legal-page {
    max-width: 780px;
    margin: 0 auto;
}

.legal-section {
    margin-bottom: 34px;
}

    .legal-section h2 {
        font-size: 1.2rem;
        margin-bottom: 12px;
        color: var(--primary-dark);
    }

    .legal-section p {
        color: var(--text-muted);
    }

.legal-updated {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 40px;
}

/* =========================
   FOOTER
========================= */
.footer {
    background: var(--primary-dark);
    color: rgba(247, 245, 238, 0.85);
    padding: 70px 0 30px;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(247, 245, 238, 0.12);
}

.footer-brand .brand-text {
    color: var(--text-on-primary);
}

.footer-tagline {
    margin-top: 14px;
    font-size: 0.92rem;
    opacity: 0.75;
    max-width: 260px;
}

.footer-col h4 {
    color: var(--text-on-primary);
    font-size: 0.98rem;
    margin-bottom: 18px;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col a {
    font-size: 0.9rem;
    opacity: 0.78;
    transition: opacity 0.2s ease;
}

    .footer-col a:hover {
        opacity: 1;
        color: var(--accent);
    }

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

    .footer-social a {
        width: 38px;
        height: 38px;
        border-radius: 50%;
        background: rgba(247, 245, 238, 0.08);
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background 0.2s ease;
    }

        .footer-social a:hover {
            background: var(--accent);
            color: #302209;
        }

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 26px;
    font-size: 0.85rem;
    opacity: 0.7;
    flex-wrap: wrap;
    gap: 10px;
}

/* =========================
   TOAST / DIALOG
========================= */
.toast-container {
    position: fixed;
    bottom: 24px;
    inset-inline-end: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--text);
    color: #fff;
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transform: translateY(10px);
    animation: toast-in 0.25s ease forwards;
    min-width: 260px;
}

    .toast.success {
        background: var(--success);
    }

    .toast.error {
        background: var(--danger);
    }

@keyframes toast-in {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.toast.is-leaving {
    animation: toast-out 0.25s ease forwards;
}

@keyframes toast-out {
    to {
        opacity: 0;
        transform: translateY(10px);
    }
}

.dialog-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 30, 30, 0.5);
    z-index: 2100;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    padding: 20px;
}

    .dialog-overlay.is-open {
        opacity: 1;
        visibility: visible;
    }

.dialog-box {
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: 30px;
    max-width: 380px;
    width: 100%;
    text-align: center;
    transform: scale(0.95);
    transition: transform 0.2s ease;
}

.dialog-overlay.is-open .dialog-box {
    transform: scale(1);
}

.dialog-box i {
    font-size: 2rem;
    color: var(--danger);
    margin-bottom: 14px;
}

.dialog-box h3 {
    margin-bottom: 10px;
}

.dialog-box p {
    color: var(--text-muted);
    margin-bottom: 24px;
    font-size: 0.92rem;
}

.dialog-actions {
    display: flex;
    gap: 12px;
}

    .dialog-actions .btn {
        flex: 1;
    }

/* =========================
   LOADING
========================= */
.loading-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.is-loading {
    pointer-events: none;
    opacity: 0.75;
}

/* Skeleton loading للبروفايلز */
.skeleton {
    background: linear-gradient(90deg, var(--surface-alt) 25%, var(--border) 50%, var(--surface-alt) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.4s ease infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
    }

    .hero-visual {
        order: -1;
    }

    .search-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .profiles-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

    .trust-strip {
        grid-template-columns: repeat(2, 1fr);
    }

    .search-page-layout {
        grid-template-columns: 1fr;
    }

    .filters-panel {
        display: none;
    }

    .mobile-filters-btn {
        display: inline-flex;
    }

    .profile-header {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .profile-header-photo {
        max-width: 180px;
        margin: 0 auto;
    }

    .profile-header-tags,
    .profile-header-actions {
        justify-content: center;
    }

    .profile-body-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-layout {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar {
        position: fixed;
        top: var(--nav-height);
        bottom: 0;
        right: 0;
        width: 260px;
        z-index: 900;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        overflow-y: auto;
    }

        .dashboard-sidebar.is-open {
            transform: translateX(0);
        }

    .mobile-sidebar-toggle {
        display: inline-flex;
        margin-bottom: 20px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-top {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .nav-links,
    .nav-actions {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    .section {
        padding: 60px 0;
    }

    .search-grid {
        grid-template-columns: 1fr;
    }

    .field-row {
        grid-template-columns: 1fr 1fr;
    }

    .profiles-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid {
        grid-template-columns: 1fr;
    }

    .trust-strip {
        grid-template-columns: 1fr;
        padding: 30px 22px;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .messages-layout {
        grid-template-columns: 1fr;
        height: auto;
    }

    .conversations-list {
        max-height: 300px;
    }

    .chat-panel {
        height: 480px;
    }

    .footer-top {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-visual-badge {
        position: static;
        margin-top: 16px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero-title {
        font-size: 1.9rem;
    }

    .search-box {
        padding: 20px;
    }

    .auth-card,
    .form-card {
        padding: 26px;
    }
}


/* =========================
   COMPACT SPACING REFINEMENT
   يحافظ على الهوية البصرية مع تقليل الفراغات الرأسية والأفقية
========================= */
:root {
    --nav-height: 72px;
}

.section {
    padding: 64px 0;
}

.section-head {
    margin-bottom: 34px;
}

.eyebrow {
    margin-bottom: 12px;
    padding: 5px 14px;
}

.section-title {
    margin-bottom: 10px;
}

.btn {
    padding: 12px 26px;
}

.btn-sm {
    padding: 8px 16px;
}

.nav-links {
    gap: 24px;
}

.mobile-menu {
    padding: 24px;
    gap: 20px;
}

    .mobile-menu a {
        padding-bottom: 12px;
    }

.hero {
    padding: 48px 0 42px;
}

.hero-inner {
    gap: 34px;
}

.hero-title {
    margin-bottom: 14px;
}

.hero-desc {
    margin-bottom: 24px;
}

.hero-actions {
    gap: 12px;
    margin-bottom: 24px;
}

.hero-trust {
    gap: 20px;
}

.search-box {
    padding: 24px;
    margin-top: -36px;
}

.search-box-title {
    margin-bottom: 14px;
}

.search-grid {
    gap: 12px;
}

.field {
    gap: 5px;
}

.profiles-grid,
.steps-grid {
    gap: 18px;
}

.profile-card-media {
    height: 190px;
}

.profile-card-body {
    padding: 16px;
}

.profile-card-bio {
    margin-bottom: 12px;
}

.featured-cta {
    margin-top: 28px;
}

.step-card {
    padding: 22px 18px;
}

.step-number {
    margin-bottom: 12px;
}

.step-card h4 {
    margin-bottom: 8px;
}

.why-grid {
    gap: 20px;
}

.why-card {
    gap: 12px;
}

.why-icon {
    width: 46px;
    height: 46px;
    font-size: 1.15rem;
}

.trust-strip {
    gap: 18px;
    padding: 32px 28px;
}

.trust-strip-item i {
    margin-bottom: 8px;
}

.cta-band {
    padding: 42px 24px;
}

    .cta-band p {
        margin-bottom: 24px;
    }

.auth-wrapper {
    padding: 40px 20px;
}

.auth-card {
    padding: 34px;
}

.auth-card-head {
    margin-bottom: 22px;
}

.form-card {
    padding: 30px;
}

.form-section {
    margin-bottom: 24px;
}

.form-section-title {
    margin: 18px 0 14px;
}

.form-grid {
    gap: 14px;
}

.profile-header {
    padding: 28px;
    gap: 22px;
    margin-bottom: 22px;
}

.profile-header-tags {
    gap: 8px;
    margin-bottom: 14px;
}

.profile-body-grid {
    gap: 18px;
}

.profile-section-card {
    padding: 20px;
    margin-bottom: 14px;
}

.dashboard-sidebar {
    padding: 24px 16px;
}

.dashboard-main {
    padding: 28px;
}

.dashboard-welcome {
    margin-bottom: 22px;
}

.stats-grid {
    gap: 14px;
    margin-bottom: 28px;
}

.stat-card {
    padding: 18px;
    gap: 12px;
}

.messages-layout {
    height: 600px;
}

.chat-messages {
    padding: 18px;
    gap: 10px;
}

.notification-card {
    gap: 12px;
    padding: 14px 16px;
    margin-bottom: 9px;
}

.settings-section {
    padding: 20px;
    margin-bottom: 16px;
}

    .settings-section h3 {
        margin-bottom: 14px;
    }

.settings-row {
    padding: 11px 0;
}

.accordion-item {
    margin-bottom: 10px;
}

.accordion-trigger {
    padding: 16px 20px;
}

.accordion-panel-inner {
    padding: 0 20px 16px;
}

.legal-section {
    margin-bottom: 24px;
}

.legal-updated {
    margin-bottom: 28px;
}

.footer {
    padding: 48px 0 24px;
}

.footer-top {
    gap: 28px;
    padding-bottom: 28px;
}

.footer-col h4 {
    margin-bottom: 14px;
}

.footer-col ul {
    gap: 9px;
}

.footer-social {
    margin-top: 12px;
}

.footer-bottom {
    padding-top: 18px;
}

@media (max-width: 768px) {
    .section {
        padding: 50px 0;
    }

    .hero {
        padding: 36px 0 32px;
    }

    .search-box {
        margin-top: -24px;
    }

    .dashboard-main {
        padding: 22px 16px;
    }
}

@media (max-width: 480px) {
    .search-box {
        padding: 18px;
    }

    .auth-card,
    .form-card {
        padding: 24px 20px;
    }
}

/* نهاية تعديل المسافات */




/* Select2 داخل الحقول */
.select2-container {
    width: 100% !important;
    font-family: var(--font-body);
}

.select2-container--default .select2-selection--single {
    height: 46px;
    display: flex;
    align-items: center;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
}

    .select2-container--default .select2-selection--single .select2-selection__rendered {
        width: 100%;
        color: var(--text);
        line-height: 44px;
        padding: 0 14px 0 38px;
        text-align: right;
    }

    .select2-container--default .select2-selection--single .select2-selection__placeholder {
        color: var(--text-muted);
    }

    /* وضع السهم في الجهة اليسرى في RTL */
    .select2-container--default .select2-selection--single .select2-selection__arrow {
        top: 0;
        left: 8px;
        right: auto;
        width: 24px;
        height: 44px;
    }

        .select2-container--default .select2-selection--single .select2-selection__arrow b {
            position: absolute;
            top: 50%;
            left: 50%;
            width: 0;
            height: 0;
            margin-left: -4px;
            margin-top: -2px;
            border-width: 5px 4px 0;
            border-style: solid;
            border-color: var(--text-muted) transparent transparent transparent;
        }

.select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--primary);
}

.select2-dropdown {
    z-index: 2000;
    border: 1.5px solid var(--primary);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.select2-search--dropdown {
    padding: 8px;
}

    .select2-search--dropdown .select2-search__field {
        width: 100%;
        padding: 9px 12px;
        border: 1px solid var(--border);
        border-radius: var(--radius-sm);
        font-family: var(--font-body);
        text-align: right;
    }

.select2-results__option {
    padding: 10px 14px;
    text-align: right;
    font-family: var(--font-body);
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background: var(--primary);
    color: var(--text-on-primary);
}





/* ============================================================
   جداول متجاوبة: تتحوّل صفوفها إلى بطاقات على الجوال.
   الاستخدام: أضِف class="resp-table" على وسم <table>،
   وأضِف data-label="اسم العمود" على كل <td>.
   انسخ هذا البلوك إلى نهاية ملف style.css.
============================================================ */
@media (max-width: 640px) {
    table.resp-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    table.resp-table,
    table.resp-table tbody,
    table.resp-table tr,
    table.resp-table td {
        display: block;
        width: 100%;
    }

        table.resp-table tr {
            border: 1px solid var(--border);
            border-radius: var(--radius-md);
            background: var(--surface);
            box-shadow: var(--shadow-sm);
            margin-bottom: 12px;
            padding: 6px 12px;
        }

        table.resp-table td {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 14px;
            white-space: normal; /* السماح بالالتفاف */
            border: none;
            border-bottom: 1px solid var(--border);
            padding: 10px 2px;
            text-align: left; /* القيمة لليسار، العنوان لليمين */
        }

            table.resp-table td:last-child {
                border-bottom: none;
            }

            /* عنوان العمود من data-label */
            table.resp-table td::before {
                content: attr(data-label);
                font-weight: 700;
                color: var(--text-muted);
                font-family: var(--font-display);
                font-size: .82rem;
                flex: 0 0 40%;
                text-align: right;
            }

            /* الخلايا التي لا تحمل عنوانًا (أزرار/إجراءات) تُعرض بعرض كامل موسّطة */
            table.resp-table td:not([data-label]) {
                justify-content: center;
            }

                table.resp-table td:not([data-label])::before {
                    content: "";
                    display: none;
                }

    /* حاوية الجدول: أزِل التمرير الأفقي على الجوال (لم نعد بحاجته) */
    .results-table-wrap,
    .u-table-wrap,
    .ops-table-wrap,
    .a-table-wrap {
        overflow-x: visible;
        border: none;
        background: transparent;
    }
}
