/* ========== INSIGHT PAGE CSS ========== */

:root {
    --electric-blue: #00ffff;
    --dark-bg: #030014;
    --glass-bg: rgba(10, 5, 40, 0.5);
    --border-glow: 0 0 15px rgba(0, 255, 255, 0.5), 0 0 5px rgba(0, 255, 255, 1);
    --text-glow: 0 0 10px rgba(0, 255, 255, 0.7);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark-bg);
    color: #E0E0E0;
    cursor: none;
    /* Hide default cursor */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Poppins', sans-serif;
    letter-spacing: 0.025em;
}

/* Custom Cursor */
.cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    background-color: var(--electric-blue);
    border-radius: 50%;
    left: 0;
    top: 0;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
    transition: width 0.2s, height 0.2s;
}

.cursor-outline {
    position: fixed;
    width: 30px;
    height: 30px;
    border: 2px solid var(--electric-blue);
    border-radius: 50%;
    left: 0;
    top: 0;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
    transition: all 0.1s ease-out;
    opacity: 0.5;
}

/* Cursor hover effects */
a:hover~.cursor-outline,
button:hover~.cursor-outline {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0.8;
    box-shadow: var(--border-glow);
}

a:hover~.cursor-dot,
button:hover~.cursor-dot {
    width: 0;
    height: 0;
}

/* Hide custom cursor in text inputs */
input[type="text"]:hover~.cursor-dot,
input[type="email"]:hover~.cursor-dot,
input[type="tel"]:hover~.cursor-dot,
textarea:hover~.cursor-dot,
select:hover~.cursor-dot {
    opacity: 0;
}

input[type="text"]:hover~.cursor-outline,
input[type="email"]:hover~.cursor-outline,
input[type="tel"]:hover~.cursor-outline,
textarea:hover~.cursor-outline,
select:hover~.cursor-outline {
    opacity: 0;
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-bg);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader-content {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    color: var(--electric-blue);
    text-shadow: var(--text-glow);
    animation: pulse 1.5s infinite ease-in-out;
}

/* Glassmorphism */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2), 0 0 30px rgba(0, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.glass-panel:hover {
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.1), 0 0 40px rgba(0, 255, 255, 0.2);
    border-color: rgba(0, 255, 255, 0.2);
}

/* Glowing Button */
.btn-glow {
    background: var(--electric-blue);
    color: #000;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    box-shadow: var(--border-glow);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-glow:hover {
    box-shadow: 0 0 25px rgba(0, 255, 255, 0.8), 0 0 10px rgba(0, 255, 255, 1);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--electric-blue);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    border: 2px solid var(--electric-blue);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-outline:hover {
    background: var(--electric-blue);
    color: #000;
    box-shadow: var(--border-glow);
    transform: translateY(-2px);
}

/* Navbar */
#navbar {
    background: rgba(3, 0, 20, 0.3);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(0, 255, 255, 0.1);
    transition: background 0.3s ease;
}

/* Navbar Corner Brackets */
.nav-corners::before,
.nav-corners::after {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    border-color: rgba(255, 255, 255, 0.3);
    border-style: solid;
    transition: all 0.3s ease;
}

.nav-corners::before {
    top: 0;
    left: 0;
    border-width: 2px 0 0 2px;
}

.nav-corners::after {
    bottom: 0;
    right: 0;
    border-width: 0 2px 2px 0;
}

/* Hero Graphics */
.hud-corners::before,
.hud-corners::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 50px;
    border-color: rgba(0, 255, 255, 0.3);
    border-style: solid;
    pointer-events: none;
}

.hud-corners::before {
    top: 2rem;
    left: 2rem;
    border-width: 3px 0 0 3px;
}

.hud-corners::after {
    bottom: 2rem;
    right: 2rem;
    border-width: 0 3px 3px 0;
}

.scan-line {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(to right, transparent, rgba(0, 255, 255, 0.5), transparent);
    animation: scan 8s linear infinite;
    opacity: 0.7;
}

/* Subtle Dot Grid Overlay */
.dot-grid {
    background-image: radial-gradient(rgba(0, 255, 255, 0.07) 1px, transparent 1px);
    background-position: 0 0;
    background-size: 20px 20px;
}

/* Form Input Glow */
.form-input {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.2);
    color: white;
    transition: all 0.3s ease;
}

.form-input:focus {
    background: rgba(0, 0, 0, 0.1);
    border-color: var(--electric-blue);
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
    outline: none;
}

/* Custom select styling */
.custom-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke-width='3' stroke='%2300ffff'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19.5 8.25l-7.5 7.5-7.5-7.5' /%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
    padding-right: 2.5rem;
}

/* Animations */
@keyframes scan {
    0% {
        transform: translateY(-100%);
    }

    100% {
        transform: translateY(120vh);
    }
}

@keyframes pulse {
    0%,
    100% {
        opacity: 0.4;
        transform: scale(0.95);
    }

    50% {
        opacity: 0.8;
        transform: scale(1.05);
    }
}

/* Accessibility Focus Ring */
:focus-visible {
    outline: 2px solid var(--electric-blue);
    outline-offset: 2px;
    box-shadow: var(--border-glow);
    border-radius: 4px;
}

/* Mobile Menu Blur */
.content-blur {
    transition: filter 0.3s ease;
}

.content-blur.blurred {
    filter: blur(10px) brightness(0.5);
    pointer-events: none;
}

/* Article Modal */
#article-modal {
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#article-modal.open {
    visibility: visible;
    opacity: 1;
}

#modal-content-wrapper {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s ease 0.1s, transform 0.3s ease 0.1s;
}

#article-modal.open #modal-content-wrapper {
    opacity: 1;
    transform: scale(1);
}

/* Modal scrollbar */
#modal-scrollable-content::-webkit-scrollbar {
    width: 8px;
}

#modal-scrollable-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

#modal-scrollable-content::-webkit-scrollbar-thumb {
    background: var(--electric-blue);
    border-radius: 4px;
}

#modal-scrollable-content::-webkit-scrollbar-thumb:hover {
    background: #00c0c0;
}

/* Tailwind Typography Overrides for dark mode */
.prose-custom {
    color: #E0E0E0;
}

.prose-custom h1,
.prose-custom h2,
.prose-custom h3,
.prose-custom h4 {
    color: #FFFFFF;
    font-family: 'Poppins', sans-serif;
}

.prose-custom strong {
    color: #FFFFFF;
}

.prose-custom a {
    color: var(--electric-blue);
    text-decoration: none;
    transition: color 0.2s;
}

.prose-custom a:hover {
    color: #00c0c0;
}

.prose-custom blockquote {
    color: #a0a0a0;
    border-left-color: var(--electric-blue);
}

.prose-custom ul>li::marker {
    color: var(--electric-blue);
}

.prose-custom code {
    color: var(--electric-blue);
    background-color: rgba(0, 255, 255, 0.1);
    padding: 0.2em 0.4em;
    border-radius: 4px;
}

.prose-custom pre {
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.1);
}
