/* 
   Xfence - Enterprise Security Platform
   Theme: White Cyberpunk / High-Tech Security
   Palette: Stark White, Deep Black, Neon Cyan, Hot Pink
*/

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;700&family=Rajdhani:wght@400;500;600;700&family=Inter:wght@300;400;600&display=swap');

:root {
    /* Core Base */
    --bg-core: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-panel: #ffffff;

    /* Text */
    --text-main: #09090b;
    /* Zinc 950 */
    --text-body: #52525b;
    /* Zinc 600 */
    --text-muted: #a1a1aa;
    /* Zinc 400 */

    /* Cyberpunk Accents */
    --cyber-blue: #00f3ff;
    --cyber-pink: #ff0099;
    --cyber-yellow: #ffee00;
    --cyber-violet: #bd00ff;

    /* Functional Colors */
    --primary: #000000;
    --primary-hover: #1a1a1a;
    --success: #00d26a;
    --danger: #ef4444;
    --warning: #f59e0b;
    --info: var(--cyber-blue);

    /* Borders & Tech Lines */
    --border-light: #e4e4e7;
    --border-strong: #000000;
    --border-tech: rgba(0, 243, 255, 0.5);

    /* Legacy/Compat */
    --slate-900: #000000;
    --slate-800: #111111;

    /* Typography */
    --font-display: 'Rajdhani', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Effects */
    --shadow-flat: 4px 4px 0px rgba(0, 0, 0, 1);
    --shadow-neon: 0 0 10px rgba(0, 243, 255, 0.4);
    --transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);

    /* Bootstrap Overrides */
    --bs-primary: var(--primary);
    --bs-body-bg: var(--bg-core);
    --bs-body-color: var(--text-main);
    --bs-success: var(--success);
    --bs-info: var(--info);
    --bs-warning: var(--warning);
    --bs-danger: var(--danger);
}

/* -------------------------------------------------------------------------- */
/*                                BASE RESET                                  */
/* -------------------------------------------------------------------------- */

body {
    background-color: var(--bg-core);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    background-image:
        linear-gradient(rgba(226, 232, 240, 0.3) 1px, transparent 1px),
        linear-gradient(90deg, rgba(226, 232, 240, 0.3) 1px, transparent 1px);
    background-size: 40px 40px;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-main);
    line-height: 1.1;
}

a {
    text-decoration: none;
    color: var(--primary);
    position: relative;
    transition: var(--transition);
}

a:not(.btn):hover {
    color: var(--cyber-pink);
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border: 2px solid white;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--cyber-pink);
}

.text-gradient {
    color: var(--primary);
    /* Fallback */
    background: linear-gradient(90deg, var(--text-main) 0%, var(--text-body) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-tech {
    font-family: var(--font-mono);
    font-size: 0.8em;
    color: var(--cyber-blue);
    text-transform: uppercase;
}

/* -------------------------------------------------------------------------- */
/*                                COMPONENTS                                  */
/* -------------------------------------------------------------------------- */

/* Buttons */
.btn {
    position: relative;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-display);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    z-index: 1;
}

.btn-primary {
    background: var(--primary);
    color: var(--cyber-blue);
    border: 1px solid transparent;
}

.btn-primary:hover {
    background: var(--primary-hover);
    color: #fff;
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0 var(--cyber-blue);
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 2px;
    right: 2px;
    width: 4px;
    height: 4px;
    background: white;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-strong);
    color: var(--text-main);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
    box-shadow: 4px 4px 0 var(--cyber-pink);
}

.btn-light {
    background: white;
    border: 1px solid var(--border-light);
    color: var(--primary);
}

.btn-light:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 4px 4px 0 var(--cyber-yellow);
}

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

.btn-danger:hover {
    background: var(--danger);
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.5);
    filter: brightness(1.1);
}

/* Cards & Containers */
.card {
    background: var(--bg-panel);
    border: 1px solid var(--border-light);
    border-radius: 0;
    position: relative;
    box-shadow: none;
    transition: var(--transition);
}

.card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    width: 20px;
    height: 20px;
    border-top: 2px solid var(--cyber-blue);
    border-left: 2px solid var(--cyber-blue);
    z-index: 2;
    transition: var(--transition);
}

.card::after {
    content: '';
    position: absolute;
    bottom: -1px;
    right: -1px;
    width: 20px;
    height: 20px;
    border-bottom: 2px solid var(--cyber-pink);
    border-right: 2px solid var(--cyber-pink);
    z-index: 2;
    transition: var(--transition);
}

.card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.05);
}

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--border-light);
    padding: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    margin: 0;
    font-weight: 700;
}

.card-body {
    padding: 1.5rem;
}

/* Tables */
.table {
    --bs-table-bg: transparent;
    border-collapse: separate;
    border-spacing: 0 0.5rem;
}

.table th {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    border-bottom: 2px solid var(--primary);
    padding: 1rem;
    letter-spacing: 0.05em;
}

.table td {
    background: white;
    border-top: 1px solid var(--border-light);
    padding: 1rem;
    vertical-align: middle;
}

.table tr:hover td {
    background: #f8fafc;
    border-color: var(--cyber-blue);
}


/* -------------------------------------------------------------------------- */
/*                                LANDING PAGE                                */
/* -------------------------------------------------------------------------- */

/* Navbar */
.navbar {
    padding: 1.5rem 0;
    background: transparent;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-light);
}

.navbar-brand {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary) !important;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: var(--cyber-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    clip-path: polygon(25% 0%, 100% 0%, 75% 100%, 0% 100%);
}

.navbar-links {
    display: flex;
    gap: 2rem;
    margin: 0 auto;
}

.nav-link {
    font-family: var(--font-mono);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    color: var(--text-main) !important;
}

.nav-link:hover {
    color: var(--primary) !important;
    text-shadow: 2px 2px 0px rgba(0, 243, 255, 0.4);
}

/* Hero Section */
.hero-section {
    padding: 10rem 0 8rem;
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at 50% 50%, #ffffff 0%, #f1f5f9 100%);
}

/* Decorative tech lines */
.hero-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        linear-gradient(90deg, transparent 95%, var(--border-light) 95%),
        linear-gradient(transparent 95%, var(--border-light) 95%);
    background-size: 100px 100px;
    opacity: 0.5;
    pointer-events: none;
}

.hero-badge {
    background: white;
    border: 1px solid var(--border-strong);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    text-transform: uppercase;
    margin-bottom: 2rem;
    box-shadow: 4px 4px 0 var(--border-light);
}

.hero-badge i {
    color: var(--cyber-blue);
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.hero-title span {
    color: transparent;
    -webkit-text-stroke: 1px var(--primary);
    position: relative;
}

.hero-title span::before {
    content: attr(data-text);
    /* This would need JS or static HTML attr, falling back to simple styling for now */
    position: absolute;
    left: 4px;
    top: 4px;
    color: var(--cyber-blue);
    z-index: -1;
    -webkit-text-stroke: 0;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-body);
    max-width: 600px;
    margin-bottom: 3rem;
    border-left: 4px solid var(--cyber-pink);
    padding-left: 1.5rem;
}

.shield-3d-container {
    position: relative;
    width: 400px;
    height: 400px;
    margin: 0 auto;
}

/* Abstract Tech Object instead of standard shield */
.shield-core {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 240px;
    background: linear-gradient(135deg, #000, #222);
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 4rem;
    z-index: 10;
    border: 2px solid var(--cyber-blue);
    box-shadow: 0 0 30px rgba(0, 243, 255, 0.3);
}

.shield-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border: 1px dashed var(--text-muted);
    border-radius: 50%;
    z-index: 1;
}

.shield-ring.outer {
    width: 380px;
    height: 380px;
    border-color: var(--primary);
    animation: spin 30s linear infinite;
}

.shield-ring.inner {
    width: 280px;
    height: 280px;
    border-style: solid;
    border-color: var(--cyber-pink);
    border-width: 1px;
    border-left-color: transparent;
    border-right-color: transparent;
    animation: spin-reverse 20s linear infinite;
}

.floating-card {
    background: white;
    border: 1px solid var(--primary);
    padding: 1rem;
    position: absolute;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
    z-index: 20;
    min-width: 200px;
}

.floating-card::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    right: 2px;
    bottom: 2px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    pointer-events: none;
}

.card-1 {
    top: 10%;
    right: -20px;
    animation: float 6s ease-in-out infinite;
    border-left: 4px solid var(--danger);
}

.card-2 {
    bottom: 15%;
    left: -20px;
    animation: float 8s ease-in-out infinite reverse;
    border-left: 4px solid var(--success);
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes spin {
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes spin-reverse {
    100% {
        transform: translate(-50%, -50%) rotate(-360deg);
    }
}

/* Stats Bar */
.stats-section {
    position: relative;
    z-index: 20;
    margin-top: -4rem;
}

.stats-grid {
    background: var(--primary);
    color: white;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    padding: 3rem;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
}

.stat-item {
    text-align: center;
    padding: 0 2rem;
    border-right: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-item:last-child {
    border-right: none;
}

.stat-item h2 {
    color: var(--cyber-blue);
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    font-family: var(--font-mono);
}

.stat-item p {
    color: #fff;
    opacity: 0.8;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    margin: 0;
}

/* Features */
.features-section {
    padding: 8rem 0;
    background: var(--bg-core);
}

.feature-card {
    height: 100%;
    padding: 2.5rem;
    background: white;
    border: 1px solid var(--border-light);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    border-color: var(--primary);
    transform: translateY(-5px);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--cyber-pink), var(--cyber-blue));
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-icon-wrapper {
    width: 60px;
    height: 60px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    clip-path: polygon(0 0, 100% 0, 100% 75%, 75% 100%, 0 100%);
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

/* Process */
.process-section {
    background: #000;
    color: white;
    padding: 8rem 0;
    position: relative;
}

.process-section .section-title,
.process-section .section-subtitle,
.process-section h4 {
    color: white;
}

.process-steps {
    display: flex;
    justify-content: space-between;
    margin-top: 4rem;
    position: relative;
}

.process-step {
    flex: 1;
    text-align: center;
    padding: 0 1rem;
    position: relative;
    z-index: 2;
}

.step-number {
    font-family: var(--font-mono);
    font-size: 4rem;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 1px var(--cyber-blue);
    opacity: 0.5;
    margin-bottom: 1rem;
    display: block;
}

.process-step:hover .step-number {
    color: var(--cyber-blue);
    opacity: 1;
}

/* Call to Action */
.cta-section {
    padding: 6rem 0;
    background: var(--bg-core);
}

.cta-box {
    background: var(--bg-secondary);
    border: 2px solid var(--primary);
    padding: 4rem;
    position: relative;
    overflow: hidden;
}

.cta-box::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--cyber-blue) 0%, transparent 70%);
    opacity: 0.1;
    filter: blur(50px);
}

/* Footer */
footer {
    background: var(--bg-core);
    border-top: 5px solid var(--primary);
    padding: 4rem 0 2rem;
}

.footer-brand {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.footer-heading {
    font-family: var(--font-mono);
    color: var(--text-main);
    text-transform: uppercase;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    border-left: 2px solid var(--cyber-pink);
    padding-left: 0.5rem;
}

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

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-body);
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.newsletter-form {
    display: flex;
    margin-top: 1rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid var(--border-light);
    border-right: none;
    background: white;
    outline: none;
}

.newsletter-form button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0 1.25rem;
    cursor: pointer;
}

.footer-bottom {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-light);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Modal */
.custom-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1050;
    /* Higher than navbar */
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
}

.modal-container {
    background: white;
    width: 100%;
    max-width: 450px;
    position: relative;
    border: 2px solid var(--primary);
    box-shadow: 20px 20px 0 rgba(0, 0, 0, 0.1);
}



.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-secondary);
}

.modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
}

.modal-close {
    background: transparent;
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--danger);
}

.modal-body {
    padding: 2rem;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 1rem;
    color: var(--text-muted);
    z-index: 1;
}

.input-wrapper input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.8rem;
    border: 1px solid var(--border-light);
    background: #fdfdfd;
    transition: var(--transition);
    font-family: var(--font-body);
}

.input-wrapper input:focus {
    border-color: var(--primary);
    background: white;
    box-shadow: 4px 4px 0 var(--border-light);
    outline: none;
}

/* Forms */
.form-control,
.form-select {
    background: var(--bg-core);
    border: 1px solid var(--border-light);
    border-radius: 0;
    padding: 0.75rem 1rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-main);
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    background: white;
    border-color: var(--cyber-blue);
    box-shadow: 0 0 0 1px var(--cyber-blue);
    outline: none;
}

/* -------------------------------------------------------------------------- */
/*                                DASHBOARD                                  */
/* -------------------------------------------------------------------------- */

.sidebar {
    width: 260px;
    height: 100vh;
    background: var(--primary);
    color: white;
    padding: 1.5rem;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
}

.sidebar-brand {
    color: white;
    font-family: var(--font-display);
    font-size: 1.75rem;
    margin-bottom: 3rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sidebar-brand i {
    color: var(--cyber-blue);
}

.sidebar .nav-pills .nav-link {
    color: #ffffff;
    padding: 0.85rem 1rem;
    border-radius: 0;
    margin-bottom: 0.5rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 1px;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
    /* Intense Neon Glow Stack */
    text-shadow:
        0 0 5px #fff,
        0 0 10px #fff,
        0 0 20px #00f3ff,
        0 0 30px #00f3ff,
        0 0 40px #00f3ff;
}

.sidebar .nav-pills .nav-link:hover,
.sidebar .nav-pills .nav-link.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
    border-left-color: var(--cyber-blue);
    text-shadow: 0 0 8px rgba(0, 243, 255, 0.6);
}

.content-wrapper {
    margin-left: 260px;
    padding: 2rem;
    background: #f3f4f6;
    min-height: 100vh;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card,
.stats-card {
    background: white;
    border: 1px solid var(--border-light);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    position: relative;
    overflow: hidden;
}

.stat-card::after,
.stats-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary);
}

.stat-icon {
    width: 50px;
    height: 50px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.stat-info h3 {
    margin: 0;
    font-size: 1.5rem;
    font-family: var(--font-mono);
}

/* Utilities */
.shadow-neon {
    box-shadow: var(--shadow-neon);
}

.border-tech {
    border: 1px solid var(--border-tech);
}

.text-cyber-blue {
    color: var(--cyber-blue) !important;
}

.text-cyber-pink {
    color: var(--cyber-pink) !important;
}

.bg-black {
    background-color: black !important;
    color: white;
}