/* ==========================================================================
   CSS Variables & Theme
   ========================================================================== */
:root {
    /* Color Palette */
    --bg-main: #050a15;
    --bg-secondary: #0a1122;
    --bg-surface: rgba(10, 17, 34, 0.6);
    
    --accent-blue: #00f0ff;
    --accent-blue-dim: rgba(0, 240, 255, 0.15);
    --accent-green: #00ff66;
    --accent-green-dim: rgba(0, 255, 102, 0.15);
    
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --text-dark: #050a15;
    
    /* Typography */
    --font-sans: 'Inter', sans-serif;
    --font-mono: 'Fira Code', monospace;
    
    /* Effects */
    --shadow-neon-blue: 0 0 15px rgba(0, 240, 255, 0.3);
    --shadow-neon-green: 0 0 15px rgba(0, 255, 102, 0.3);
    --glass-border: 1px solid rgba(0, 240, 255, 0.1);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* ==========================================================================
   Base Reset
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: var(--font-sans);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-sans);
    font-weight: 700;
    line-height: 1.2;
}

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

a:hover {
    color: var(--text-main);
    text-shadow: 0 0 8px var(--accent-blue);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-padding {
    padding: 6rem 0;
}

/* Typography Utilities */
.terminal-prompt {
    color: var(--accent-green);
    font-family: var(--font-mono);
    font-weight: bold;
}

/* ==========================================================================
   Navigation
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    z-index: 1000;
    background: rgba(5, 10, 21, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 1rem 5%;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    border-bottom: var(--glass-border);
}

.nav-brand {
    font-family: var(--font-mono);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent-blue);
}

.hamburger {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--accent-blue);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-primary, .btn-secondary, .btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-primary {
    background-color: var(--accent-blue);
    color: var(--text-dark);
    border: 1px solid var(--accent-blue);
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--accent-blue);
    box-shadow: var(--shadow-neon-blue);
}

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

.btn-secondary:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
}

.btn-outline {
    background-color: transparent;
    color: var(--accent-blue);
    border: 1px solid var(--accent-blue);
    padding: 0.5rem 1rem;
}

.btn-outline:hover {
    background-color: var(--accent-blue-dim);
    box-shadow: var(--shadow-neon-blue);
}

.w-100 { width: 100%; }

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding: 0 5%;
    overflow: hidden;
}

#hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.6;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.cyber-subtitle {
    font-family: var(--font-mono);
    color: var(--accent-green);
    font-size: 0.9rem;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: var(--accent-green-dim);
    border: 1px solid var(--accent-green);
    border-radius: 3px;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5.5rem);
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: var(--text-main);
    line-height: 1.1;
    letter-spacing: -2px;
}

.hero h2 {
    font-size: clamp(1.2rem, 3vw, 2rem);
    color: var(--text-muted);
    font-weight: 400;
    margin-bottom: 2rem;
    min-height: 2.4rem;
}

.typewriter-container {
    display: flex;
    align-items: center;
}

.cursor {
    display: inline-block;
    width: 10px;
    color: var(--accent-blue);
    animation: blink 1s step-end infinite;
}

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

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.stat-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-surface);
    padding: 0.75rem 1.25rem;
    border-radius: 4px;
    border: var(--glass-border);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    border-left: 3px solid var(--accent-blue);
}

.stat-badge.success {
    border-left-color: var(--accent-green);
}

.stat-badge i {
    color: var(--accent-blue);
}

.stat-badge.success i {
    color: var(--accent-green);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--text-muted);
    border-radius: 14px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 6px;
    background: var(--accent-blue);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

@keyframes scroll {
    0% { top: 6px; opacity: 1; }
    100% { top: 20px; opacity: 0; }
}

/* ==========================================================================
   Section Headers
   ========================================================================== */
.section-header {
    display: flex;
    align-items: center;
    margin-bottom: 4rem;
}

.section-header.center {
    justify-content: center;
    flex-direction: column;
    text-align: center;
}

.section-header h2 {
    font-size: 2rem;
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.header-num {
    font-family: var(--font-mono);
    color: var(--accent-blue);
    font-size: 1.5rem;
    margin-right: 1rem;
    font-weight: 400;
}

.line {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    flex-grow: 1;
    margin-left: 2rem;
}

.section-header.center .line {
    width: 100px;
    margin: 1rem auto 0;
    flex-grow: 0;
}

/* ==========================================================================
   About Section
   ========================================================================== */
.about-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 4rem;
    align-items: center;
}

.about-text .lead {
    font-size: 1.25rem;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.about-text p {
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

.about-text strong {
    color: var(--accent-blue);
    font-weight: 600;
}

.about-highlights {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-main);
}

.highlight-item i {
    color: var(--accent-green);
    font-size: 1.25rem;
}

.about-image-container {
    position: relative;
    max-width: 400px;
    margin: 0 auto;
}

.image-wrapper {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    z-index: 1;
}

.image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    filter: grayscale(100%) contrast(1.1);
    transition: var(--transition);
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--accent-blue-dim);
    mix-blend-mode: screen;
    transition: var(--transition);
}

.image-wrapper:hover img {
    filter: grayscale(0%) contrast(1);
}

.image-wrapper:hover .image-overlay {
    background: transparent;
}

.image-frame {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    border: 2px solid var(--accent-blue);
    border-radius: 8px;
    z-index: -1;
    transition: var(--transition);
}

.image-wrapper:hover + .image-frame,
.image-wrapper:hover ~ .image-frame {
    top: 10px;
    left: 10px;
}

.image-caption {
    margin-top: 2rem;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 0.85rem;
}

/* ==========================================================================
   Expertise Section
   ========================================================================== */
.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--bg-surface);
    border: var(--glass-border);
    border-radius: 8px;
    padding: 2.5rem 2rem;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent-blue);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border-color: rgba(0, 240, 255, 0.3);
}

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

.card-icon {
    font-size: 2.5rem;
    color: var(--accent-blue);
    margin-bottom: 1.5rem;
}

.card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* ==========================================================================
   Projects Section
   ========================================================================== */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 16px;
    height: 100%;
    width: 2px;
    background: rgba(255, 255, 255, 0.1);
}

.timeline-item {
    position: relative;
    padding-left: 3rem;
    margin-bottom: 3rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    position: absolute;
    top: 5px;
    left: 11px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-blue);
    box-shadow: var(--shadow-neon-blue);
}

.timeline-content {
    background: var(--bg-surface);
    border: var(--glass-border);
    padding: 2rem;
    border-radius: 8px;
    transition: var(--transition);
}

.timeline-content:hover {
    border-color: rgba(0, 240, 255, 0.3);
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

.timeline-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-tags span {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--accent-green);
    background: var(--accent-green-dim);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
}

.timeline-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* ==========================================================================
   Skills Section
   ========================================================================== */
.skills-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.skill-category {
    background: var(--bg-surface);
    border: var(--glass-border);
    border-radius: 8px;
    padding: 2rem;
}

.skill-category h3 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.skill-category h3 i {
    color: var(--accent-blue);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skill-tags .tag {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.skill-tags .tag:hover {
    background: var(--accent-blue-dim);
    border-color: var(--accent-blue);
    color: var(--text-main);
    transform: translateY(-2px);
}

.skill-tags .tag.crowdstrike:hover {
    background: rgba(255, 0, 0, 0.1);
    border-color: #ff0000;
}

.skill-tags .tag.cert:hover {
    background: var(--accent-green-dim);
    border-color: var(--accent-green);
}

/* ==========================================================================
   Contact Section
   ========================================================================== */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    background: var(--bg-surface);
    border: var(--glass-border);
    border-radius: 8px;
    padding: 3rem;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.contact-info p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-link-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-main);
}

.contact-link-item:hover .icon-box {
    background: var(--accent-blue);
    color: var(--text-dark);
}

.icon-box {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--accent-blue);
    transition: var(--transition);
}

.contact-link-item h4 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.contact-link-item span {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent-blue);
}

.form-group input,
.form-group textarea {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 1rem;
    color: var(--text-main);
    font-family: var(--font-sans);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.1);
}

.form-status {
    margin-top: 1rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    text-align: center;
}

.form-status.success { color: var(--accent-green); }
.form-status.error { color: #ff3333; }

/* ==========================================================================
   Footer
   ========================================================================== */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-brand {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text-main);
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    color: var(--text-muted);
    font-size: 1.5rem;
}

.footer-social a:hover {
    color: var(--accent-blue);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ==========================================================================
   Animations & Utilities
   ========================================================================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Glitch Effect applied on hover or initial load */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-main);
}

.glitch::before {
    left: 2px;
    text-shadow: -1px 0 var(--accent-blue);
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-2 3s infinite linear alternate-reverse;
    z-index: -1;
}

.glitch::after {
    left: -2px;
    text-shadow: -1px 0 var(--accent-green);
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim 2.5s infinite linear alternate-reverse;
    z-index: -2;
}

@keyframes glitch-anim {
    0% { clip: rect(10px, 9999px, 86px, 0); }
    5% { clip: rect(61px, 9999px, 9px, 0); }
    10% { clip: rect(26px, 9999px, 89px, 0); }
    15% { clip: rect(4px, 9999px, 92px, 0); }
    20% { clip: rect(32px, 9999px, 14px, 0); }
    25% { clip: rect(98px, 9999px, 2px, 0); }
    30% { clip: rect(15px, 9999px, 100px, 0); }
    35% { clip: rect(69px, 9999px, 63px, 0); }
    40% { clip: rect(7px, 9999px, 42px, 0); }
    45% { clip: rect(48px, 9999px, 81px, 0); }
    50% { clip: rect(89px, 9999px, 12px, 0); }
    55% { clip: rect(33px, 9999px, 55px, 0); }
    60% { clip: rect(11px, 9999px, 21px, 0); }
    65% { clip: rect(52px, 9999px, 99px, 0); }
    70% { clip: rect(88px, 9999px, 34px, 0); }
    75% { clip: rect(2px, 9999px, 78px, 0); }
    80% { clip: rect(63px, 9999px, 4px, 0); }
    85% { clip: rect(39px, 9999px, 67px, 0); }
    90% { clip: rect(91px, 9999px, 18px, 0); }
    95% { clip: rect(17px, 9999px, 94px, 0); }
    100% { clip: rect(55px, 9999px, 46px, 0); }
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */
@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .about-image-container {
        grid-row: 1;
        margin-bottom: 2rem;
    }
    
    .contact-wrapper {
        grid-template-columns: 1fr;
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
    }
    
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: var(--bg-secondary);
        flex-direction: column;
        justify-content: center;
        transition: 0.5s ease;
        border-left: 1px solid rgba(255, 255, 255, 0.05);
        box-shadow: -5px 0 20px rgba(0,0,0,0.5);
    }
    
    .nav-links.active {
        right: 0;
    }
    
    .timeline::before {
        left: 0;
    }
    
    .timeline-item {
        padding-left: 2rem;
    }
    
    .timeline-dot {
        left: -5px;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
        white-space: normal;
        line-height: 1.4;
    }
    
    .header-num {
        font-size: 1.25rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-actions {
        flex-direction: column;
    }
    
    .btn-primary, .btn-secondary {
        width: 100%;
    }
    
    .section-padding {
        padding: 4rem 0;
    }
    
    .section-header h2 {
        font-size: 1.3rem;
    }
    
    .header-num {
        font-size: 1.1rem;
    }
    
    .line {
        margin-left: 1rem;
    }
}

