/*
Theme Name: Lexalyze
Theme URI: https://lexalyze.ai
Author: Mahmood Khosravian / Lexalyze Team
Description: Lexalyze - AI-Powered Compliance Platform. Redesigned with Belyad Fire cyber-tech aesthetics.
Version: 3.0.0
Text Domain: lexalyze
License: Proprietary
*/

/* ============================================
   CSS VARIABLES & ROOT STYLES
   ============================================ */
:root {
    /* Primary Colors from Cyber Theme */
    --primary-dark: #1a2332;
    --primary-darker: #0f1419;
    --secondary-dark: #2d3748;
    --accent-orange: #ff6b35;
    --accent-orange-light: #ff8c5a;
    --accent-cyan: #00d4ff;
    --accent-cyan-light: #4de8ff;
    --text-light: #e2e8f0;
    --text-muted: #94a3b8;
    --border-glow: rgba(0, 212, 255, 0.3);

    /* Gradients */
    --gradient-dark: linear-gradient(135deg, #1a2332 0%, #0f1419 100%);
    --gradient-card: linear-gradient(145deg, rgba(45, 55, 72, 0.8) 0%, rgba(26, 35, 50, 0.9) 100%);
    --gradient-orange: linear-gradient(135deg, #ff6b35 0%, #ff8c5a 100%);
    --gradient-cyan: linear-gradient(135deg, #00d4ff 0%, #4de8ff 100%);

    /* Legacy compatibility */
    --primary: var(--accent-cyan);
    --primary-light: var(--accent-cyan-light);
    --text: var(--text-light);
    --muted: var(--text-muted);
    --muted-light: var(--text-muted);
    --border: rgba(255, 255, 255, 0.1);
    --bg: var(--primary-darker);
    --bg-dark: var(--primary-dark);
    --card: rgba(45, 55, 72, 0.6);
    --glass: rgba(26, 35, 50, 0.9);

    /* Color aliases for backwards compatibility */
    --success: #0F9D58;
    --success-dark: #0B7F3A;
    --warning: #F9AB00;
    --warning-dark: #D38B00;
    --danger: #EA4335;
    --danger-dark: #9C2A24;
    --purple: #9333EA;
    --purple-dark: #7E22CE;
    --teal: #14B8A6;
    --teal-dark: #0D9488;
    --indigo: #6366F1;
    --indigo-dark: #4F46E5;

    /* Typography */
    --font-display: 'Orbitron', 'Rajdhani', sans-serif;
    --font-body: 'Exo 2', 'Segoe UI', 'Inter', sans-serif;

    /* Spacing */
    --section-padding: 120px;
    --container-max: 1400px;
    --max-width: 1400px;
    --header-height: 70px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-sm: 8px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);

    /* Shadows - Cyber Style */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.7);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.8);
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    background: var(--primary-darker);
    color: var(--text-light);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

a {
    color: var(--accent-cyan);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--accent-cyan-light);
}

img {
    max-width: 100%;
    height: auto;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-light);
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-muted);
}

ul, ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.5rem;
}

/* ============================================
   ANIMATED BACKGROUND
   ============================================ */
.cyber-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: var(--gradient-dark);
    overflow: hidden;
}

.cyber-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at 20% 80%, rgba(255, 107, 53, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(0, 212, 255, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(45, 55, 72, 0.5) 0%, transparent 70%);
    animation: pulseGlow 8s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Grid Pattern */
.grid-pattern {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image:
        linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(60px, 60px); }
}

/* Floating Particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--accent-cyan);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-cyan), 0 0 20px var(--accent-cyan);
    animation: float 15s infinite;
    opacity: 0.6;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 20s; }
.particle:nth-child(2) { left: 20%; animation-delay: 2s; animation-duration: 18s; }
.particle:nth-child(3) { left: 30%; animation-delay: 4s; animation-duration: 22s; }
.particle:nth-child(4) { left: 40%; animation-delay: 1s; animation-duration: 17s; }
.particle:nth-child(5) { left: 50%; animation-delay: 3s; animation-duration: 21s; }
.particle:nth-child(6) { left: 60%; animation-delay: 5s; animation-duration: 19s; }
.particle:nth-child(7) { left: 70%; animation-delay: 2.5s; animation-duration: 16s; }
.particle:nth-child(8) { left: 80%; animation-delay: 4.5s; animation-duration: 23s; }
.particle:nth-child(9) { left: 90%; animation-delay: 1.5s; animation-duration: 20s; }

@keyframes float {
    0%, 100% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
        transform: translateY(90vh) scale(1);
    }
    90% {
        opacity: 0.6;
        transform: translateY(10vh) scale(1);
    }
    100% {
        transform: translateY(-10vh) scale(0);
        opacity: 0;
    }
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 30px;
}

.wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
}

main {
    flex: 1;
    position: relative;
    z-index: 1;
}

/* ============================================
   HEADER / NAVIGATION
   ============================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 12px 0;
    transition: var(--transition);
    backdrop-filter: blur(0px);
}

.site-header.scrolled {
    background: rgba(15, 20, 25, 0.95);
    backdrop-filter: blur(20px);
    padding: 10px 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid var(--border-glow);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 30px;
    height: auto;
}

.site-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--text-light);
    transition: var(--transition);
}

.site-brand:hover {
    color: var(--accent-cyan);
    transform: scale(1.05);
}

.site-brand img {
    height: 36px;
    width: auto;
    filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.3));
    transition: var(--transition);
}

.site-brand:hover img {
    filter: drop-shadow(0 0 20px rgba(0, 212, 255, 0.5));
}

.site-brand .logo-text {
    font-size: 20px;
    background: var(--gradient-cyan);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Navigation */
.main-navigation {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-menu {
    display: flex;
    gap: 40px;
    list-style: none;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-light);
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    padding: 8px 0;
}

.nav-menu a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-cyan);
    transition: var(--transition);
}

.nav-menu a:hover {
    color: var(--accent-cyan);
}

.nav-menu a:hover::before {
    width: 100%;
}

.nav-menu a.active {
    color: var(--accent-cyan);
}

.nav-menu a.active::before {
    width: 100%;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    padding: 10px;
    background: transparent;
    border: none;
}

.mobile-menu-toggle span {
    width: 28px;
    height: 2px;
    background: var(--text-light);
    transition: var(--transition-fast);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient-orange);
    color: white;
    box-shadow: 0 4px 25px rgba(255, 107, 53, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 40px rgba(255, 107, 53, 0.6);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: var(--accent-cyan);
    border: 2px solid var(--accent-cyan);
}

.btn-secondary:hover {
    background: rgba(0, 212, 255, 0.1);
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.3);
    transform: translateY(-3px);
}

.btn-outline {
    background: transparent;
    color: var(--text-light);
    border: 2px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--accent-cyan);
    color: var(--accent-cyan);
    background: rgba(0, 212, 255, 0.05);
}

.btn-ghost {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    backdrop-filter: blur(10px);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.3);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
}

.btn-lg {
    padding: 18px 40px;
    font-size: 17px;
}

/* ============================================
   CARDS
   ============================================ */
.card {
    background: var(--gradient-card);
    border-radius: var(--radius);
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow);
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.card:hover {
    transform: translateY(-8px);
    border-color: var(--border-glow);
    box-shadow: var(--shadow-lg);
}

.card-header {
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.card-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    color: var(--text-light);
}

.card-body {
    color: var(--text-muted);
    font-size: 15px;
}

.card-footer {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ============================================
   ALERTS & NOTIFICATIONS
   ============================================ */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius);
    margin: 16px 0;
    display: flex;
    align-items: start;
    gap: 12px;
    border-left: 4px solid;
    background: rgba(26, 35, 50, 0.6);
    backdrop-filter: blur(10px);
}

.alert-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.alert-info {
    border-color: var(--accent-cyan);
    color: var(--accent-cyan);
}

.alert-success {
    border-color: var(--success);
    color: var(--success);
}

.alert-warning {
    border-color: var(--warning);
    color: var(--warning);
}

.alert-danger {
    border-color: var(--danger);
    color: var(--danger);
}

/* ============================================
   BADGES & PILLS
   ============================================ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-primary {
    background: var(--gradient-cyan);
    color: white;
}

.badge-success {
    background: var(--success);
    color: white;
}

.badge-warning {
    background: var(--warning);
    color: white;
}

.badge-danger {
    background: var(--danger);
    color: white;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-light);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    font-size: 15px;
    font-family: inherit;
    transition: var(--transition-fast);
    background: rgba(45, 55, 72, 0.5);
    color: var(--text-light);
    backdrop-filter: blur(10px);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--accent-cyan);
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.2);
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

.form-input::placeholder {
    color: var(--text-muted);
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: var(--gradient-card);
    border-top: 1px solid var(--border-glow);
    padding: 48px 0 24px;
    margin-top: 80px;
    backdrop-filter: blur(20px);
}

.footer-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 32px;
}

.footer-section h4 {
    margin-bottom: 16px;
    font-size: 16px;
    color: var(--text-light);
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section li {
    margin-bottom: 12px;
}

.footer-section a {
    color: var(--text-muted);
    font-size: 14px;
    transition: var(--transition-fast);
}

.footer-section a:hover {
    color: var(--accent-cyan);
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-copyright {
    color: var(--muted);
    font-size: 14px;
}

.footer-links {
    display: flex;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-links a {
    color: var(--muted);
    font-size: 14px;
}

/* ============================================
   UTILITIES
   ============================================ */

/* Spacing */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

/* Text Alignment */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

/* Text Colors */
.text-primary { color: var(--accent-cyan); }
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-danger { color: var(--danger); }
.text-muted { color: var(--muted); }

/* Display */
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.d-grid { display: grid; }

/* Flex Utilities */
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.fade-in { animation: fadeIn 0.6s ease forwards; }
.fade-in-up { animation: fadeInUp 0.6s ease forwards; }
.slide-in-right { animation: slideInRight 0.6s ease forwards; }

/* ============================================
   CUSTOM SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--primary-darker);
}

::-webkit-scrollbar-thumb {
    background: var(--secondary-dark);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-cyan);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Tablet */
@media (max-width: 968px) {
    :root {
        --max-width: 100%;
        --section-padding: 80px;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.375rem; }

    .nav-menu {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .main-navigation.mobile-open .nav-menu {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(15, 20, 25, 0.98);
        padding: 20px;
        box-shadow: var(--shadow-lg);
        border-radius: 0 0 var(--radius) var(--radius);
        backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border-glow);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Mobile */
@media (max-width: 640px) {
    .container {
        padding: 0 16px;
    }

    .header-inner {
        padding: 12px 16px;
    }

    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }

    .btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .site-header,
    .site-footer,
    .btn,
    .mobile-menu-toggle,
    .cyber-bg,
    .grid-pattern,
    .particles {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    .card {
        box-shadow: none;
        border: 1px solid #ddd;
        background: white;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--accent-cyan);
    color: var(--primary-darker);
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
}

.skip-link:focus {
    top: 0;
}

/* Focus Styles */
*:focus-visible {
    outline: 2px solid var(--accent-cyan);
    outline-offset: 2px;
}
