/* ========================================
   CSS Custom Properties (Theme Variables)
   ======================================== */
:root {
    /* Dark Theme Colors */
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-tertiary: #1a1a1a;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --text-muted: #666666;

    /* Neon Accent Colors */
    --neon-cyan: #00f5ff;
    --neon-magenta: #ff00ff;
    --neon-green: #39ff14;
    --neon-blue: #0ff;

    /* UI Colors */
    --border-color: #333333;
    --card-bg: rgba(26, 26, 26, 0.8);
    --glass-bg: rgba(255, 255, 255, 0.05);

    /* Shadows & Glows */
    --glow-cyan: 0 0 10px var(--neon-cyan), 0 0 20px var(--neon-cyan);
    --glow-magenta: 0 0 10px var(--neon-magenta), 0 0 20px var(--neon-magenta);
    --glow-green: 0 0 10px var(--neon-green), 0 0 20px var(--neon-green);

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 3rem;
    --spacing-xl: 4rem;

    /* Typography */
    --font-mono: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Courier New', monospace;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

/* ========================================
   Reset & Base Styles
   ======================================== */
* {
    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-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Grid Background Pattern */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(0, 245, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 245, 255, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: -1;
    opacity: 0.3;
}

/* ========================================
   Navigation
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: var(--spacing-sm) 0;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-primary);
}

.terminal-prompt {
    color: var(--neon-cyan);
    margin-right: 0.5rem;
}

.nav-links {
    display: flex;
    gap: var(--spacing-md);
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-magenta));
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: var(--neon-cyan);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Suckless Navigation Button - Terminal Style */
.nav-suckless {
    color: var(--neon-green) !important;
}

.nav-suckless:hover {
    color: var(--neon-green) !important;
    text-shadow: var(--glow-green);
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.icon-btn {
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.icon-btn:hover {
    background: var(--neon-cyan);
    color: var(--bg-primary);
    border-color: var(--neon-cyan);
    box-shadow: var(--glow-cyan);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: var(--spacing-xl) var(--spacing-md);
}

.hero-container {
    max-width: 1200px;
    text-align: center;
}

.hero h1 {
    font-size: clamp(3.5rem, 10vw, 7rem);
    font-family: var(--font-mono);
    font-weight: bold;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
    position: relative;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.hero-roles {
    font-family: var(--font-mono);
    font-size: clamp(1.25rem, 3vw, 2rem);
    margin-bottom: var(--spacing-lg);
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0;
}

.role-line {
    display: inline-block;
    text-align: center;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
    letter-spacing: 0.05em;
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards;
    text-shadow: 0 0 20px rgba(0, 245, 255, 0.3);
}

.role-line::after {
    content: ' · ';
    margin: 0 0.5rem;
    color: var(--neon-cyan);
    background: none;
    -webkit-text-fill-color: var(--neon-cyan);
}

.role-line:last-child::after {
    content: '';
    margin: 0;
}

.role-line:nth-child(1) {
    animation-delay: 0.2s;
}

.role-line:nth-child(2) {
    animation-delay: 0.4s;
}

.role-line:nth-child(3) {
    animation-delay: 0.6s;
}

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

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    color: var(--text-secondary);
    max-width: 700px;
    margin: var(--spacing-md) auto;
    line-height: 1.6;
}

/* Hero Links */
.hero-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: var(--spacing-lg);
    flex-wrap: wrap;
}

.hero-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.hero-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 245, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.hero-link:hover::before {
    left: 100%;
}

.hero-link-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    transition: all 0.3s ease;
}

.hero-link-icon svg {
    width: 100%;
    height: 100%;
}

.hero-link-text {
    transition: all 0.3s ease;
}

/* Individual link colors & hover states */
.hero-link:nth-child(1):hover,
.hero-link:nth-child(1):active {
    border-color: var(--neon-cyan);
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.4);
    transform: translateY(-2px);
}

.hero-link:nth-child(1):hover .hero-link-icon,
.hero-link:nth-child(1):active .hero-link-icon {
    color: var(--neon-cyan);
    transform: scale(1.05);
    filter: drop-shadow(0 0 8px var(--neon-cyan));
}

.hero-link:nth-child(1):hover .hero-link-text,
.hero-link:nth-child(1):active .hero-link-text {
    color: var(--neon-cyan);
}

.hero-link:nth-child(2):hover,
.hero-link:nth-child(2):active {
    border-color: var(--neon-green);
    box-shadow: 0 0 20px rgba(57, 255, 20, 0.4);
    transform: translateY(-2px);
}

.hero-link:nth-child(2):hover .hero-link-icon,
.hero-link:nth-child(2):active .hero-link-icon {
    color: var(--neon-green);
    transform: scale(1.05);
    filter: drop-shadow(0 0 8px var(--neon-green));
}

.hero-link:nth-child(2):hover .hero-link-text,
.hero-link:nth-child(2):active .hero-link-text {
    color: var(--neon-green);
}

.hero-link:nth-child(3):hover,
.hero-link:nth-child(3):active {
    border-color: var(--neon-magenta);
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.4);
    transform: translateY(-2px);
}

.hero-link:nth-child(3):hover .hero-link-icon,
.hero-link:nth-child(3):active .hero-link-icon {
    color: var(--neon-magenta);
    transform: scale(1.05);
    filter: drop-shadow(0 0 8px var(--neon-magenta));
}

.hero-link:nth-child(3):hover .hero-link-text,
.hero-link:nth-child(3):active .hero-link-text {
    color: var(--neon-magenta);
}

/* Active/tap states for mobile */
.hero-link:active {
    transform: translateY(0) scale(0.98);
}

/* Touch device optimization */
@media (hover: none) and (pointer: coarse) {
    .hero-link {
        transition: all 0.2s ease;
    }

    .hero-link:active {
        transform: scale(0.97);
        opacity: 0.9;
    }
}

.scroll-indicator {
    position: absolute;
    bottom: var(--spacing-lg);
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.scroll-arrow {
    margin-top: var(--spacing-xs);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
    color: var(--neon-cyan);
}

/* ========================================
   Section Containers
   ======================================== */
section {
    padding: var(--spacing-xl) var(--spacing-md);
    min-height: 100vh;
}

.section-container {
    max-width: 1400px;
    margin: 0 auto;
}

.section-title {
    font-family: var(--font-mono);
    font-size: 2rem;
    margin-bottom: var(--spacing-lg);
    color: var(--text-primary);
}

/* ========================================
   Skills Section
   ======================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.skill-category {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: var(--spacing-md);
    transition: all 0.3s ease;
}

.skill-category:hover {
    border-color: var(--neon-cyan);
    box-shadow: var(--glow-cyan);
    transform: translateY(-5px);
}

.category-title {
    font-family: var(--font-mono);
    font-size: 1.3rem;
    color: var(--neon-cyan);
    margin-bottom: var(--spacing-sm);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
}

.skill-tag {
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.skill-tag:hover {
    border-color: var(--neon-magenta);
    color: var(--neon-magenta);
    box-shadow: var(--glow-magenta);
}

/* ========================================
   Contact Section
   ======================================== */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.contact-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.contact-link {
    font-family: var(--font-mono);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
}

.contact-link:hover {
    color: var(--neon-cyan);
    text-shadow: var(--glow-cyan);
    transform: translateX(10px);
}

/* Contact Form */
.contact-form {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: var(--spacing-md);
}

.form-group {
    margin-bottom: var(--spacing-sm);
}

.form-group label {
    display: block;
    font-family: var(--font-mono);
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 0.8rem;
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--neon-cyan);
    box-shadow: var(--glow-cyan);
}

.submit-btn {
    background: var(--glass-bg);
    border: 1px solid var(--neon-cyan);
    color: var(--neon-cyan);
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.submit-btn:hover {
    background: var(--neon-cyan);
    color: var(--bg-primary);
    box-shadow: var(--glow-cyan);
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: var(--spacing-md);
    text-align: center;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
}

.footer p {
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.footer-meta {
    margin-top: var(--spacing-xs);
    color: var(--text-muted);
}

/* Hamburger Menu Button (Mobile Only) */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 0.5rem;
    background: transparent;
    border: none;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--neon-cyan);
    border-radius: 2px;
    transition: all 0.3s ease;
    box-shadow: 0 0 5px var(--neon-cyan);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 968px) {
    html {
        font-size: 16px;
    }

    /* Mobile Navigation */
    .hamburger {
        display: flex;
    }

    .nav-container {
        position: relative;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 70%;
        max-width: 300px;
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: var(--spacing-lg);
        transition: right 0.4s ease;
        z-index: 1000;
        border-left: 1px solid var(--border-color);
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.5);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
        padding: 0.5rem 1rem;
        width: 80%;
        text-align: center;
        border: 1px solid transparent;
        border-radius: 8px;
        transition: all 0.3s ease;
    }

    .nav-links a:hover,
    .nav-links a.active {
        border-color: var(--neon-cyan);
        background: rgba(0, 245, 255, 0.1);
    }

    .logo {
        font-size: 1rem;
    }

    /* Hero Section - Professional Mobile Design */
    .hero {
        padding: 80px 24px 48px;
        min-height: 100vh;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .hero-container {
        width: 100%;
        max-width: 540px;
        margin: 0 auto;
    }

    .hero h1 {
        font-size: 3.5rem;
        font-weight: 700;
        margin-bottom: 20px;
        line-height: 1.05;
        letter-spacing: -0.03em;
    }

    .hero-roles {
        font-size: 1.125rem;
        margin-bottom: 28px;
        gap: 6px;
        flex-direction: column;
    }

    .role-line::after {
        display: none;
    }

    .hero-subtitle {
        font-size: 1.0625rem;
        padding: 0;
        line-height: 1.6;
        margin-bottom: 40px;
        max-width: 480px;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-links {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-top: 0;
        padding: 0;
        max-width: 400px;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-link {
        padding: 14px 20px;
        font-size: 0.9375rem;
        width: 100%;
        max-width: none;
        justify-content: center;
        min-height: 48px;
        font-weight: 500;
    }

    .hero-link-icon {
        width: 20px;
        height: 20px;
    }

    .scroll-indicator {
        bottom: 24px;
    }

    /* Sections */
    section {
        padding: var(--spacing-lg) var(--spacing-sm);
        min-height: auto;
    }

    .section-title {
        font-size: 1.5rem;
        margin-bottom: var(--spacing-md);
    }

    /* Skills Grid */
    .skills-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .skill-category {
        padding: var(--spacing-sm);
    }

    .category-title {
        font-size: 1.1rem;
    }

    .skill-tag {
        font-size: 0.8rem;
        padding: 0.3rem 0.6rem;
    }

    /* Contact Section */
    .contact-container {
        grid-template-columns: 1fr;
    }

    .contact-card {
        width: 100% !important;
        max-width: 100% !important;
    }

    .contact-text {
        font-size: 1rem !important;
    }

    /* Scroll Indicator */
    .scroll-indicator {
        bottom: var(--spacing-sm);
        font-size: 0.8rem;
    }

    .scroll-arrow {
        font-size: 1.2rem;
    }
}

@media (max-width: 640px) {
    html {
        font-size: 16px;
    }

    .navbar {
        padding: 0.75rem 0;
    }

    .nav-container {
        padding: 0 20px;
    }

    .nav-links {
        width: 80%;
    }

    .logo {
        font-size: 0.9rem;
    }

    /* Hero Section - Refined for Small Screens */
    .hero {
        padding: 72px 20px 40px;
        min-height: 100vh;
    }

    .hero-container {
        max-width: 100%;
        padding: 0;
    }

    .hero h1 {
        font-size: 4rem;
        font-weight: 700;
        margin-bottom: 18px;
        line-height: 1.05;
        letter-spacing: -0.03em;
    }

    .hero-roles {
        font-size: 1rem;
        margin-bottom: 24px;
        gap: 5px;
    }

    .hero-subtitle {
        font-size: 1rem;
        padding: 0;
        line-height: 1.6;
        margin-bottom: 32px;
        max-width: 100%;
    }

    .hero-links {
        gap: 10px;
        max-width: 100%;
    }

    .hero-link {
        padding: 13px 18px;
        font-size: 0.875rem;
        min-height: 48px;
        font-weight: 500;
    }

    .hero-link-icon {
        width: 20px;
        height: 20px;
        flex-shrink: 0;
    }

    .hero-link-text {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Scroll indicator - hide on mobile */
    .scroll-indicator {
        display: none;
    }

    section {
        padding: var(--spacing-md) var(--spacing-xs);
    }

    .section-container {
        padding: 0;
    }

    .section-title {
        font-size: 1.3rem;
        margin-bottom: var(--spacing-sm);
    }

    .skills-grid {
        gap: var(--spacing-sm);
    }

    .skill-category {
        padding: var(--spacing-sm);
    }

    .category-title {
        font-size: 1rem;
        margin-bottom: var(--spacing-xs);
    }

    .skill-tags {
        gap: 0.4rem;
    }

    .skill-tag {
        font-size: 0.75rem;
        padding: 0.3rem 0.5rem;
    }

    .contact-text {
        font-size: 0.95rem !important;
        margin-bottom: var(--spacing-md) !important;
    }

    .footer {
        padding: var(--spacing-sm);
    }

    .footer p {
        font-size: 0.8rem;
    }

    /* Background Grid - Smaller on mobile */
    body::before {
        background-size: 30px 30px;
        opacity: 0.2;
    }
}

/* Extra Small Screens - iPhone SE, etc (Professional Design) */
@media (max-width: 375px) {
    html {
        font-size: 16px;
    }

    .hero {
        padding: 64px 16px 32px;
    }

    .hero h1 {
        font-size: 3.25rem;
        font-weight: 700;
        margin-bottom: 16px;
        line-height: 1.05;
        letter-spacing: -0.03em;
    }

    .hero-roles {
        font-size: 0.9375rem;
        margin-bottom: 20px;
        gap: 4px;
    }

    .hero-subtitle {
        font-size: 0.9375rem;
        padding: 0;
        line-height: 1.6;
        margin-bottom: 28px;
    }

    .hero-links {
        gap: 8px;
    }

    .hero-link {
        padding: 12px 16px;
        font-size: 0.8125rem;
        min-height: 44px;
        gap: 8px;
    }

    .hero-link-icon {
        width: 18px;
        height: 18px;
    }

    .logo {
        font-size: 0.875rem;
    }

    .nav-links a {
        font-size: 1.1rem;
    }
}

/* ========================================
   Animations
   ======================================== */
@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

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