/* ==========================================================
   REXTO GLOBAL - MODERN & PROFESSIONAL CORE STYLESHEET
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #f59e0b;
    --primary-hover: #d97706;
    --primary-glow: rgba(245, 158, 11, 0.18);
    --dark-bg: #0b0f19;
    --card-dark: #111827;
    --border-dark: #1f2937;
}

/* Global Font & Smoothness */
html {
    scroll-behavior: smooth;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    letter-spacing: -0.01em;
}

/* Glassmorphism Header
   Scope this rule to the main site header used by header.php.
   The generic `header` selector is intentionally avoided so embedded
   widgets or other semantic headers are not unexpectedly restyled. */
header:not(.rg-footer) {
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    background-color: rgba(255, 255, 255, 0.85) !important;
}

.dark header:not(.rg-footer) {
    background-color: rgba(15, 23, 42, 0.85) !important;
}

/* Sleek Search Form Box */
form.bg-white, form.dark\:bg-slate-950 {
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

form.bg-white:focus-within {
    box-shadow: 0 15px 35px -5px rgba(245, 158, 11, 0.25);
    border-color: rgba(245, 158, 11, 0.4);
}

/* Professional Cards Hover Effect
   Only apply card styling to explicitly marked cards. Broad `.grid > div`
   rules can unintentionally change forms, menus and other grid layouts. */
.rg-card,
[data-rg-card="true"] {
    position: relative;
    border: 1px solid #e2e8f0;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.dark .rg-card,
.dark [data-rg-card="true"] {
    border: 1px solid #1e293b;
    background: #0f172a;
}

.rg-card:hover,
[data-rg-card="true"]:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: rgba(245, 158, 11, 0.5);
}

/* Badge Glow & Styling */
.badge-glow {
    box-shadow: 0 0 12px var(--primary-glow);
}

/* Buttons Upgrade */
button, .button-glow, a.bg-amber-500 {
    transition: all 0.2s ease-in-out;
}

button[type="submit"]:hover, a.bg-amber-500:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 15px rgba(245, 158, 11, 0.35);
}

/* Clean Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #0b0f19;
}

::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #f59e0b;
}

/* Subtle Hero Glow */
.hero-glow-bg {
    background: radial-gradient(circle at 50% 20%, rgba(245, 158, 11, 0.12) 0%, transparent 60%), #0f172a;
}

/* Accessibility / interaction hardening */
:focus-visible {
    outline: 3px solid rgba(245, 158, 11, 0.75);
    outline-offset: 3px;
}

::selection {
    background: #f59e0b;
    color: #0b0f19;
}

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

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Avoid accidental horizontal overflow on small screens. */
html,
body {
    max-width: 100%;
    overflow-x: hidden;
}
