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

:root {
    --bg-color: #0a0e27;
    --terminal-bg: #1a1e35;
    --terminal-border: #2d3561;
    --primary-color: #00ff41;
    --secondary-color: #00d9ff;
    --text-color: #e0e0e0;
    --error-color: #ff6b6b;
    --warning-color: #ffd93d;
}

body {
    font-family: 'Fira Code', monospace;
    background: var(--bg-color);
    color: var(--text-color);
    overflow: hidden;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Matrix Background Effect */
.matrix-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, #0a0e27 0%, #1a1e35 100%);
    z-index: -1;
    overflow: hidden;
}

.matrix-bg::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(90deg, rgba(0, 255, 65, 0.03) 1px, transparent 1px),
        linear-gradient(rgba(0, 255, 65, 0.03) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: matrix-scroll 20s linear infinite;
}

@keyframes matrix-scroll {
    0% { transform: translateY(0); }
    100% { transform: translateY(20px); }
}

.container {
    width: 95%;
    max-width: 1000px;
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.8s ease-in;
}

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

.terminal {
    width: 100%;
    height: 100%;
    background: var(--terminal-bg);
    border-radius: 10px;
    box-shadow:
        0 0 20px rgba(0, 255, 65, 0.1),
        0 0 40px rgba(0, 217, 255, 0.05),
        0 20px 60px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    border: 1px solid var(--terminal-border);
    display: flex;
    flex-direction: column;
}

.terminal-header {
    background: linear-gradient(to bottom, #2d3561 0%, #252a4a 100%);
    padding: 12px 15px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--terminal-border);
    position: relative;
}

.terminal-buttons {
    display: flex;
    gap: 8px;
}

.btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s;
}

.btn:hover {
    transform: scale(1.2);
}

.btn-close {
    background: #ff5f56;
    box-shadow: 0 0 5px rgba(255, 95, 86, 0.5);
}

.btn-minimize {
    background: #ffbd2e;
    box-shadow: 0 0 5px rgba(255, 189, 46, 0.5);
}

.btn-maximize {
    background: #27c93f;
    box-shadow: 0 0 5px rgba(39, 201, 63, 0.5);
}

.terminal-title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    color: var(--secondary-color);
    font-size: 14px;
    font-weight: 500;
}

.terminal-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.6;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--terminal-bg);
}

.terminal-body::-webkit-scrollbar {
    width: 8px;
}

.terminal-body::-webkit-scrollbar-track {
    background: var(--terminal-bg);
}

.terminal-body::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

.ascii-art {
    color: var(--primary-color);
    font-size: 10px;
    line-height: 1.2;
    margin-bottom: 20px;
    white-space: pre;
    text-shadow: 0 0 10px rgba(0, 255, 65, 0.5);
}

.intro p {
    margin: 5px 0;
    animation: typewriter 0.5s steps(40) forwards;
}

.glow {
    color: var(--secondary-color);
    font-weight: 600;
    text-shadow: 0 0 10px rgba(0, 217, 255, 0.8);
    animation: glow-pulse 2s ease-in-out infinite;
}

@keyframes glow-pulse {
    0%, 100% { text-shadow: 0 0 10px rgba(0, 217, 255, 0.8); }
    50% { text-shadow: 0 0 20px rgba(0, 217, 255, 1); }
}

.highlight {
    color: var(--warning-color);
    font-weight: 600;
    background: rgba(255, 217, 61, 0.1);
    padding: 2px 6px;
    border-radius: 3px;
}

#output {
    margin: 10px 0;
}

.output-line {
    margin: 8px 0;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.command-output {
    margin-left: 0;
    color: var(--text-color);
}

.command-output h3 {
    color: var(--secondary-color);
    margin: 15px 0 10px 0;
    font-size: 16px;
}

.command-output h4 {
    color: var(--primary-color);
    margin: 10px 0 5px 0;
    font-size: 14px;
}

.command-output p {
    margin: 5px 0;
    line-height: 1.6;
}

.command-output ul {
    margin: 5px 0 10px 20px;
}

.command-output li {
    margin: 3px 0;
    list-style-type: none;
}

.command-output li::before {
    content: '▹ ';
    color: var(--primary-color);
    font-weight: bold;
}

.job {
    margin: 15px 0;
    padding: 10px;
    border-left: 3px solid var(--primary-color);
    background: rgba(0, 255, 65, 0.03);
}

.job-title {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 15px;
}

.company {
    color: var(--primary-color);
    font-weight: 500;
}

.date {
    color: var(--warning-color);
    font-size: 12px;
}

.skill-category {
    margin: 10px 0;
}

.skill-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.skill-tag {
    background: rgba(0, 255, 65, 0.1);
    color: var(--primary-color);
    padding: 4px 12px;
    border-radius: 4px;
    border: 1px solid var(--primary-color);
    font-size: 12px;
    transition: all 0.3s;
}

.skill-tag:hover {
    background: rgba(0, 255, 65, 0.2);
    box-shadow: 0 0 10px rgba(0, 255, 65, 0.3);
    transform: translateY(-2px);
}

.project {
    margin: 15px 0;
    padding: 10px;
    border-left: 3px solid var(--secondary-color);
    background: rgba(0, 217, 255, 0.03);
}

.project-title {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 15px;
}

.tech-stack {
    color: var(--warning-color);
    font-size: 12px;
    margin-top: 5px;
}

.contact-item {
    margin: 8px 0;
    color: var(--text-color);
}

.contact-item a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s;
}

.contact-item a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.input-line {
    display: flex;
    align-items: center;
    margin-top: 10px;
    position: relative;
}

.prompt {
    color: var(--primary-color);
    margin-right: 8px;
    font-weight: 600;
}

#terminal-input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-color);
    font-family: 'Fira Code', monospace;
    font-size: 14px;
    flex: 1;
    caret-color: var(--primary-color);
}

.cursor {
    display: inline-block;
    width: 8px;
    height: 18px;
    background: var(--primary-color);
    animation: blink 1s step-end infinite;
    margin-left: 2px;
}

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

.error {
    color: var(--error-color);
}

.success {
    color: var(--primary-color);
}

.info {
    color: var(--secondary-color);
}

.warning {
    color: var(--warning-color);
}

/* Help command styling */
.help-table {
    margin: 10px 0;
}

.help-row {
    display: flex;
    margin: 5px 0;
}

.help-command {
    color: var(--warning-color);
    width: 150px;
    font-weight: 600;
}

.help-description {
    color: var(--text-color);
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        width: 98%;
        height: 95vh;
    }

    .terminal-body {
        font-size: 12px;
        padding: 15px;
    }

    .ascii-art {
        font-size: 8px;
    }

    .skill-items {
        gap: 5px;
    }

    .skill-tag {
        font-size: 10px;
        padding: 3px 8px;
    }
}

/* Loading animation */
.loading {
    display: inline-block;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0%, 100% { content: '.'; }
    33% { content: '..'; }
    66% { content: '...'; }
}
