/* سند — ملف التصميم الرئيسي */
/* المسار الصحيح: /public_html/assets/css/style.css */

:root {
    --bg: #071016;
    --bg-soft: #0A1724;
    --navy: #0B1D33;
    --navy-2: #123A5A;
    --cyan: #00E0FF;
    --mint: #28D6C4;
    --white: #FFFFFF;
    --text: #EAF3F8;
    --muted: #9BAEC2;
    --border: rgba(255, 255, 255, 0.12);
    --card: rgba(255, 255, 255, 0.065);
    --danger: #FF6B6B;
    --warning: #FFD166;
    --shadow: 0 22px 60px rgba(0, 0, 0, 0.28);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    direction: rtl;
    font-family: Tahoma, Arial, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 15% 5%, rgba(0, 224, 255, 0.14), transparent 26%),
        radial-gradient(circle at 85% 0%, rgba(40, 214, 196, 0.09), transparent 26%),
        var(--bg);
    line-height: 1.8;
}

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

button,
input,
textarea,
select {
    font-family: inherit;
}

button {
    border: 0;
}

.header {
    min-height: 76px;
    padding: 16px 34px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    background: rgba(7, 16, 22, 0.86);
    backdrop-filter: blur(18px);
    position: sticky;
    top: 0;
    z-index: 20;
}

.brand {
    display: flex;
    gap: 12px;
    align-items: center;
    font-size: 24px;
    font-weight: 900;
}

.logo {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, var(--navy), var(--mint));
    font-weight: 900;
    box-shadow: 0 14px 35px rgba(0, 224, 255, 0.18);
    position: relative;
    overflow: hidden;
}

.logo::after {
    content: "";
    position: absolute;
    width: 120%;
    height: 10px;
    background: rgba(255, 255, 255, 0.15);
    transform: rotate(-32deg);
}

.logo span {
    position: relative;
    z-index: 2;
}

.nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.nav a {
    color: var(--muted);
    padding: 8px 11px;
    border-radius: 999px;
    transition: 0.2s ease;
}

.nav a:hover {
    color: var(--cyan);
    background: rgba(255, 255, 255, 0.06);
}

.container {
    width: min(1120px, calc(100% - 32px));
    margin: 34px auto;
}

/* الصفحة الرئيسية */

.hero {
    min-height: calc(100vh - 144px);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 34px;
    align-items: center;
}

.hero h1 {
    font-size: clamp(38px, 5vw, 68px);
    line-height: 1.2;
    margin: 14px 0;
}

.hero h1 span {
    color: var(--cyan);
}

.hero p,
p {
    color: var(--muted);
}

.hero p {
    font-size: 20px;
}

.actions {
    margin-top: 26px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.badge,
.pill {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(0, 224, 255, 0.10);
    color: var(--cyan);
    border: 1px solid rgba(0, 224, 255, 0.24);
    font-weight: 700;
    font-size: 13px;
}

.pill.warning {
    background: rgba(255, 209, 102, 0.12);
    color: var(--warning);
    border-color: rgba(255, 209, 102, 0.24);
}

.btn,
button {
    min-height: 42px;
    padding: 0 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--cyan), var(--mint));
    color: #041016;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 6px 4px;
    transition: 0.2s ease;
}

.btn:hover,
button:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}

.btn.secondary {
    background: rgba(255, 255, 255, 0.07);
    color: var(--text);
    border: 1px solid var(--border);
}

.card,
.hero-widget,
.auth-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.095), rgba(255, 255, 255, 0.055));
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 24px;
    margin: 18px 0;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
}

.hero-widget {
    box-shadow: var(--shadow);
    border-radius: 34px;
}

.mini-chat,
.chat-panel {
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid var(--border);
    border-radius: 26px;
    padding: 20px;
}

.mini-chat-head,
.chat-panel-head {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 18px;
}

.avatar {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, var(--navy), var(--cyan));
    font-weight: 900;
}

.avatar.big {
    width: 64px;
    height: 64px;
    font-size: 26px;
}

small {
    color: var(--mint);
}

.bubble {
    width: fit-content;
    max-width: 90%;
    padding: 12px 14px;
    border-radius: 18px;
    margin: 10px 0;
}

.bubble.bot {
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid var(--border);
}

.bubble.user {
    margin-right: auto;
    background: linear-gradient(135deg, var(--cyan), var(--mint));
    color: #041016;
    font-weight: bold;
}

.chips span,
.quick-buttons button {
    display: inline-flex;
    padding: 7px 11px;
    border-radius: 999px;
    background: rgba(0, 224, 255, 0.10);
    border: 1px solid rgba(0, 224, 255, 0.24);
    color: var(--text);
    margin: 4px;
}

.recommend-card {
    margin-top: 16px;
    padding: 16px;
    border-radius: 18px;
    background: rgba(0, 224, 255, 0.09);
    border: 1px solid rgba(0, 224, 255, 0.22);
}

.recommend-card span,
.recommend-card small {
    display: block;
    color: var(--muted);
}

.recommend-card strong {
    display: block;
    margin: 5px 0;
}

/* الأقسام */

.section {
    padding: 46px 0;
}

.section-title {
    text-align: center;
    max-width: 720px;
    margin: auto auto 24px;
}

.section-title h2 {
    font-size: clamp(28px, 4vw, 44px);
    margin: 10px 0;
}

.feature-grid,
.stats-grid,
.hero-stats,
.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.feature-grid {
    grid-template-columns: repeat(4, 1fr);
}

.feature-card,
.stat {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 22px;
}

.icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    background: rgba(0, 224, 255, 0.10);
    display: grid;
    place-items: center;
    font-size: 23px;
}

.stat strong {
    display: block;
    color: var(--cyan);
    font-size: 32px;
}

.stat span {
    color: var(--muted);
}

/* لوحات التحكم */

.page-title {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    margin-bottom: 22px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 18px;
    overflow: hidden;
    margin-top: 18px;
}

th,
td {
    padding: 13px;
    border-bottom: 1px solid var(--border);
    text-align: right;
}

th {
    color: var(--cyan);
    background: rgba(0, 224, 255, 0.06);
}

/* النماذج */

input,
textarea,
select {
    width: 100%;
    margin: 6px 0 14px;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
    outline: none;
}

input:focus,
textarea:focus,
select:focus {
    border-color: rgba(0, 224, 255, 0.65);
    box-shadow: 0 0 0 3px rgba(0, 224, 255, 0.10);
}

select option {
    color: #111;
}

label {
    display: block;
    color: var(--muted);
    font-weight: 700;
}

.form-card,
.auth-card {
    max-width: 720px;
}

/* الشات */

.chat-layout {
    max-width: 820px;
    margin: auto;
}

.chat-box {
    min-height: 320px;
    max-height: 460px;
    overflow-y: auto;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 14px;
    background: rgba(0, 0, 0, 0.18);
}

.chat-form {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}

.chat-form input {
    margin: 0;
}

code {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.25);
    color: var(--cyan);
    direction: ltr;
}

/* الجوال */

@media (max-width: 900px) {
    .hero,
    .feature-grid,
    .stats-grid,
    .hero-stats,
    .grid {
        grid-template-columns: 1fr;
    }

    .header {
        flex-direction: column;
        align-items: flex-start;
    }

    .chat-form {
        flex-direction: column;
    }

    .page-title {
        flex-direction: column;
        align-items: flex-start;
    }

    .container {
        width: min(100% - 22px, 1120px);
        margin: 22px auto;
    }

    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}
