/* TechMagic - Retro-Futuristic Terminal Aesthetic */

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

:root {
    /* Core palette - Emerald terminal on charcoal */
    --primary: #10b981;
    --primary-glow: rgba(16, 185, 129, 0.4);
    --primary-dim: #059669;
    --secondary: #f0fdf4;
    --accent: #fbbf24;
    --accent-glow: rgba(251, 191, 36, 0.3);

    /* Backgrounds */
    --bg-void: #0c0c0c;
    --bg-deep: #111111;
    --bg-surface: #1a1a1a;
    --bg-elevated: #222222;
    --bg-hover: #2a2a2a;

    /* Text */
    --text-bright: #f0fdf4;
    --text-primary: #d1d5db;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;

    /* Borders & Lines */
    --border: #2d2d2d;
    --border-active: #10b981;
    --grid-line: rgba(16, 185, 129, 0.06);

    /* Typography */
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    --font-display: 'Outfit', system-ui, sans-serif;

    /* Effects */
    --glow-sm: 0 0 10px var(--primary-glow);
    --glow-md: 0 0 20px var(--primary-glow), 0 0 40px rgba(16, 185, 129, 0.2);
    --glow-lg: 0 0 30px var(--primary-glow), 0 0 60px rgba(16, 185, 129, 0.15);
    --scanline: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.1) 2px,
        rgba(0, 0, 0, 0.1) 4px
    );

    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: var(--font-display);
    background: var(--bg-void);
    color: var(--text-primary);
    line-height: 1.7;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    position: relative;
}

/* Grid background pattern */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(var(--grid-line) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
}

/* Scanline overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background: var(--scanline);
    pointer-events: none;
    z-index: 9998;
    opacity: 0.3;
}

/* Selection */
::selection {
    background: var(--primary);
    color: var(--bg-void);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-bright);
    letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.125rem; }

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

a {
    color: var(--primary);
    text-decoration: none;
    transition: all 0.2s ease;
}

a:hover {
    color: var(--secondary);
    text-shadow: var(--glow-sm);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

/* ═══════════════════════════════════════════════════════════════
   HEADER & NAVIGATION
   ═══════════════════════════════════════════════════════════════ */

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(12, 12, 12, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo img {
    height: 45px;
    width: auto;
    border-radius: 4px;
    border: 1px solid var(--border);
}

.logo-text {
    font-family: var(--font-mono);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    text-shadow: var(--glow-sm);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 0.5rem;
}

nav a {
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.625rem 1rem;
    border-radius: 4px;
    border: 1px solid transparent;
    transition: all 0.25s ease;
    position: relative;
}

nav a::before {
    content: '>';
    position: absolute;
    left: 0.5rem;
    opacity: 0;
    color: var(--primary);
    transition: all 0.25s ease;
    transform: translateX(-5px);
}

nav a:hover,
nav a.active {
    color: var(--primary);
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.2);
    padding-left: 1.5rem;
}

nav a:hover::before,
nav a.active::before {
    opacity: 1;
    transform: translateX(0);
}

.mobile-menu-btn {
    display: none;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--primary);
    font-size: 1.25rem;
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    cursor: pointer;
    font-family: var(--font-mono);
}

/* ═══════════════════════════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════════════════════════ */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 0 5rem;
    position: relative;
    overflow: hidden;
}

/* Glowing orbs */
.hero::before {
    content: '';
    position: absolute;
    top: 20%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    animation: float 8s ease-in-out infinite;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 10%;
    right: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    animation: float 10s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-30px) scale(1.05); }
}

.hero .container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    position: relative;
}

.hero-content h1 {
    margin-bottom: 1.5rem;
    opacity: 0;
    transform: translateY(30px);
    animation: slideUp 0.8s var(--ease-out-expo) 0.2s forwards;
}

.hero-content h1 span {
    color: var(--primary);
    text-shadow: var(--glow-md);
    position: relative;
}

.tagline {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 500px;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUp 0.8s var(--ease-out-expo) 0.4s forwards;
}

/* Terminal-style label */
.hero-content::before {
    content: '// EXPERT SOFTWARE DEVELOPMENT';
    display: block;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--primary);
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeIn 0.6s ease 0.1s forwards;
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transform: translateX(40px);
    animation: slideLeft 1s var(--ease-out-expo) 0.5s forwards;
}

.profile-image {
    width: 100%;
    max-width: 380px;
    border-radius: 8px;
    border: 2px solid var(--border);
    box-shadow: var(--glow-md), 0 25px 50px rgba(0, 0, 0, 0.5);
    transition: all 0.4s var(--ease-out-expo);
    position: relative;
}

.profile-image:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: var(--primary);
    box-shadow: var(--glow-lg), 0 35px 70px rgba(0, 0, 0, 0.4);
}

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-mono);
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.875rem 1.75rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s var(--ease-out-expo);
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-primary {
    background: var(--primary);
    color: var(--bg-void);
    box-shadow: var(--glow-sm);
}

.btn-primary:hover {
    background: var(--secondary);
    color: var(--bg-void);
    transform: translateY(-2px);
    box-shadow: var(--glow-md);
}

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

.btn-outline:hover {
    background: var(--primary);
    color: var(--bg-void);
    box-shadow: var(--glow-sm);
}

.btn-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUp 0.8s var(--ease-out-expo) 0.6s forwards;
}

/* ═══════════════════════════════════════════════════════════════
   SECTIONS
   ═══════════════════════════════════════════════════════════════ */

section {
    padding: 6rem 0;
    position: relative;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 4rem;
}

.section-header h2 {
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-header h2::before {
    content: '[';
    color: var(--primary);
    margin-right: 0.5rem;
    font-weight: 300;
}

.section-header h2::after {
    content: ']';
    color: var(--primary);
    margin-left: 0.5rem;
    font-weight: 300;
}

.section-header p {
    font-size: 1.0625rem;
}

/* ═══════════════════════════════════════════════════════════════
   STATS
   ═══════════════════════════════════════════════════════════════ */

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-top: 4rem;
}

.stat-item {
    text-align: center;
    padding: 2rem 1.5rem;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-item:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.stat-item:hover::before {
    opacity: 1;
}

.stat-number {
    font-family: var(--font-mono);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    text-shadow: var(--glow-sm);
    line-height: 1;
}

.stat-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 0.75rem;
}

/* ═══════════════════════════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════════════════════════ */

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 1.5rem;
}

.card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 2rem;
    position: relative;
    transition: all 0.4s var(--ease-out-expo);
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--ease-out-expo);
}

.card:hover {
    border-color: var(--primary);
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), var(--glow-sm);
}

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

.card-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(16, 185, 129, 0.05));
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.card:hover .card-icon {
    background: var(--primary);
    border-color: var(--primary);
    box-shadow: var(--glow-md);
    transform: scale(1.1);
}

.card h3 {
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.card ul {
    list-style: none;
    margin-top: 1.25rem;
}

.card li {
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    color: var(--text-secondary);
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    border-bottom: 1px solid var(--border);
}

.card li:last-child {
    border-bottom: none;
}

.card li::before {
    content: '$';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: 600;
}

/* ═══════════════════════════════════════════════════════════════
   TECH STACK BADGES
   ═══════════════════════════════════════════════════════════════ */

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 2rem;
}

.tech-badge {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    color: var(--text-secondary);
    transition: all 0.25s ease;
}

.tech-badge:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(16, 185, 129, 0.1);
    transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════════════════
   ABOUT SECTION
   ═══════════════════════════════════════════════════════════════ */

.about-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.about-content p {
    font-size: 1.0625rem;
    margin-bottom: 1.5rem;
}

/* ═══════════════════════════════════════════════════════════════
   PAGE HEADER
   ═══════════════════════════════════════════════════════════════ */

.page-header {
    padding: 10rem 0 4rem;
    background: linear-gradient(180deg, var(--bg-void) 0%, var(--bg-deep) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    filter: blur(100px);
    opacity: 0.5;
    pointer-events: none;
}

.page-header h1 {
    position: relative;
    margin-bottom: 1rem;
}

.breadcrumb {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--text-muted);
    position: relative;
}

.breadcrumb a {
    color: var(--text-secondary);
}

.breadcrumb a:hover {
    color: var(--primary);
}

/* ═══════════════════════════════════════════════════════════════
   SERVICE DETAIL
   ═══════════════════════════════════════════════════════════════ */

.service-detail {
    padding: 4rem 0;
}

.service-content {
    max-width: 900px;
    margin: 0 auto;
}

.service-content h2 {
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    padding-left: 1rem;
    border-left: 3px solid var(--primary);
}

.service-content p {
    font-size: 1.0625rem;
    margin-bottom: 1.5rem;
}

.feature-list {
    list-style: none;
    margin: 2rem 0;
}

.feature-list li {
    padding: 1.25rem 1.5rem;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--primary);
    border-radius: 0 8px 8px 0;
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.feature-list li:hover {
    border-color: var(--primary);
    background: var(--bg-elevated);
    transform: translateX(4px);
}

.feature-list li strong {
    font-family: var(--font-mono);
    color: var(--text-bright);
    display: block;
    margin-bottom: 0.25rem;
}

/* ═══════════════════════════════════════════════════════════════
   CONTACT FORM
   ═══════════════════════════════════════════════════════════════ */

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h2,
.contact-info h3 {
    margin-bottom: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.contact-item-icon {
    width: 50px;
    height: 50px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.25rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.contact-item:hover .contact-item-icon {
    border-color: var(--primary);
    background: rgba(16, 185, 129, 0.1);
    box-shadow: var(--glow-sm);
}

.contact-form {
    background: var(--bg-surface);
    padding: 2.5rem;
    border-radius: 8px;
    border: 1px solid var(--border);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

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

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

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2310b981' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
}

.form-message {
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-family: var(--font-mono);
    font-size: 0.875rem;
    display: none;
}

.form-message.success {
    display: block;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--primary);
    color: var(--primary);
}

.form-message.error {
    display: block;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid #ef4444;
    color: #ef4444;
}

/* ═══════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════ */

footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    padding: 4rem 0 2rem;
    position: relative;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-about .logo {
    margin-bottom: 1rem;
}

.footer-about p {
    font-size: 0.9rem;
    max-width: 300px;
}

.footer-links h4 {
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
}

.footer-links ul {
    list-style: none;
}

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

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

.footer-links a:hover {
    color: var(--primary);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

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

/* ═══════════════════════════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

@keyframes slideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideLeft {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

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

/* Typing cursor effect for headings */
.hero-content h1::after {
    content: '_';
    color: var(--primary);
    animation: blink 1s step-end infinite;
    margin-left: 2px;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-image {
        order: -1;
    }

    .hero-content::before {
        text-align: center;
    }

    .tagline {
        margin-left: auto;
        margin-right: auto;
    }

    .btn-group {
        justify-content: center;
    }

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

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

    .stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }

    nav ul {
        position: fixed;
        top: 77px;
        left: 0;
        right: 0;
        background: var(--bg-deep);
        flex-direction: column;
        padding: 1.5rem;
        gap: 0.5rem;
        border-bottom: 1px solid var(--border);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s var(--ease-out-expo);
    }

    nav ul.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

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

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

    .footer-about {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-about p {
        max-width: 100%;
    }

    section {
        padding: 4rem 0;
    }

    .page-header {
        padding: 8rem 0 3rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

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

    .btn-group {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    h1 {
        font-size: 2rem;
    }

    .stat-number {
        font-size: 2rem;
    }
}
