/* ============================================================================
   STARIA-SKY-BLUE — هوية الموقع الجديدة: الأزرق السماوي والأبيض العصري.
   تُحمَّل بعد ملف Vite المبني في resources/themes/staria/views/layouts/app.blade.php
   ========================================================================== */

:root {
    --sc-cream: #f0f9ff;
    --sc-cream-2: #e0f2fe;
    --sc-paper: #ffffff;
    --sc-ink: #0c4a6e;
    --sc-ink-soft: #0369a1;
    --sc-muted: #0284c7;
    --sc-gold: #0ea5e9;
    --sc-gold-deep: #0284c7;
    --sc-line: #bae6fd;
    --sc-alert: #ef4444;
    --sc-shadow: 0 26px 60px -40px rgba(14, 165, 233, .35);
}

body {
    background:
        radial-gradient(1200px 700px at 88% -12%, #f0f9ff 0%, rgba(240, 249, 255, 0) 62%),
        radial-gradient(900px 600px at 4% 108%, #e0f2fe 0%, rgba(224, 242, 254, 0) 58%),
        linear-gradient(170deg, var(--sc-cream) 0%, var(--sc-cream-2) 100%) !important;
    color: var(--sc-ink) !important;
    -webkit-font-smoothing: antialiased;
}

/* الخلفية الناعمة المتحركة خلف الصفحة كلها */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 18% 22%, rgba(14, 165, 233, .12) 0 2px, transparent 3px),
        radial-gradient(circle at 72% 12%, rgba(2, 132, 199, .10) 0 2px, transparent 3px),
        radial-gradient(circle at 42% 78%, rgba(56, 189, 248, .10) 0 3px, transparent 4px);
    background-size: 340px 340px, 460px 460px, 620px 620px;
    animation: sc-drift 34s linear infinite;
}

@keyframes sc-drift {
    from { background-position: 0 0, 0 0, 0 0; }
    to { background-position: 340px 340px, -460px 460px, 620px -620px; }
}

/* ---------- الشريط العلوي ---------- */
header.sticky,
[data-staria-flash] {
    background: rgba(255, 255, 255, .94) !important;
    border-color: var(--sc-line) !important;
    color: var(--sc-ink) !important;
    box-shadow: 0 10px 30px -26px rgba(14, 165, 233, .5);
}

[data-staria-flash] { color: var(--sc-gold-deep) !important; }
[data-staria-flash] button { color: var(--sc-muted) !important; }

/* ---------- التذييل ---------- */
footer {
    background: linear-gradient(180deg, #f0f9ff, #e0f2fe) !important;
    border-top: 1px solid var(--sc-line) !important;
    color: var(--sc-ink-soft) !important;
}
footer a { color: var(--sc-ink-soft) !important; }
footer a:hover { color: var(--sc-gold) !important; }

/* ---------- مكوّنات الثيم ---------- */
.staria-card,
.staria-hero,
.staria-avatar-stage {
    background: var(--sc-paper) !important;
    border: 1px solid var(--sc-line) !important;
    color: var(--sc-ink) !important;
    box-shadow: var(--sc-shadow) !important;
}

.staria-card:hover { border-color: rgba(14, 165, 233, .55) !important; }

.staria-label { color: var(--sc-ink-soft) !important; }

.staria-input {
    background: #ffffff !important;
    border: 1px solid var(--sc-line) !important;
    color: var(--sc-ink) !important;
}
.staria-input::placeholder { color: #7dd3fc !important; }
.staria-input:focus {
    border-color: var(--sc-gold) !important;
    box-shadow: 0 0 0 4px rgba(14, 165, 233, .2) !important;
}

.staria-btn-gold {
    background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
    color: #ffffff !important;
    border: 0 !important;
    box-shadow: 0 14px 28px -14px rgba(14, 165, 233, .7) !important;
}
.staria-btn-gold:hover {
    filter: brightness(1.08);
    color: #ffffff !important;
}

.staria-btn-ghost {
    background: rgba(255, 255, 255, .85) !important;
    border: 1px solid var(--sc-line) !important;
    color: var(--sc-ink-soft) !important;
}
.staria-btn-ghost:hover {
    border-color: var(--sc-gold) !important;
    color: var(--sc-gold-deep) !important;
    background: rgba(240, 249, 255, 1) !important;
}

.staria-badge {
    background: rgba(14, 165, 233, .12) !important;
    border: 1px solid rgba(14, 165, 233, .35) !important;
    color: var(--sc-gold-deep) !important;
}

.staria-nav-link,
.staria-nav-link-block { color: var(--sc-ink-soft) !important; }
.staria-nav-link:hover,
.staria-nav-link-block:hover {
    color: var(--sc-gold-deep) !important;
    background: rgba(14, 165, 233, .1) !important;
}

.staria-error { color: var(--sc-alert) !important; }
.gold-text {
    background: linear-gradient(96deg, #0284c7, #38bdf8) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    color: transparent !important;
}

/* ---------- أدوات Tailwind الداكنة المستعملة في الصفحات ---------- */
.text-zinc-100, .text-zinc-200, .text-zinc-300 { color: var(--sc-ink) !important; }
.text-zinc-400, .text-zinc-500 { color: #0284c7 !important; }
.text-white { color: var(--sc-ink) !important; }
.text-gold-200, .text-gold-300, .text-gold-400 { color: #0284c7 !important; }
.text-alert-500 { color: var(--sc-alert) !important; }
.hover\:text-gold-300:hover, .hover\:text-gold-200:hover, .hover\:text-gold-400:hover { color: #0ea5e9 !important; }
.hover\:text-zinc-200:hover { color: var(--sc-ink) !important; }

.bg-night-800, .bg-night-900, .bg-night-950,
.bg-night-800\/95, .bg-night-800\/90, .bg-night-700 {
    background-color: var(--sc-paper) !important;
}
.bg-alert-500\/10 { background-color: rgba(239, 68, 68, .1) !important; }
.border-alert-500\/40 { border-color: rgba(239, 68, 68, .38) !important; }

[class*="border-night"], .border-gold-500\/15, .border-gold-500\/20, .border-gold-500\/25, .border-gold-500\/30, .border-gold-500\/35 {
    border-color: var(--sc-line) !important;
}
.hover\:border-gold-500\/40:hover { border-color: rgba(14, 165, 233, .6) !important; }

.divide-night-800 > * + *, .border-t\.border-gold { border-color: var(--sc-line) !important; }

/* الجداول والقوائم داخل الصفحات */
table, .staria-table { color: var(--sc-ink) !important; }
th { color: var(--sc-ink-soft) !important; }

@media (prefers-reduced-motion: reduce) {
    body::before { animation: none; }
}
