body {
    margin: 0;
    font-family: 'VT323', monospace;
    background-color: #000;
    color: #00ff00;
    line-height: 1.6;
    overflow-x: hidden;
}

header {
    text-align: center;
    padding: 20px;
    background: #111;
    color: #fff;
    font-size: 2em;
    border-bottom: 2px solid #ff0000;
    text-shadow: 0 0 10px #ff0000;
}

/* Makes text glitch in and out with offset colors */
header.glitch {
    position: relative;
    color: transparent;
}

header.glitch::before,
header.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 20px;
    left: 0;
    width: 100%;
    height: 100%;
}
header.glitch::before {
    color: rgb(153, 22, 22);
    left: -3px; /* Added horizontal offset */
    animation: glitchFade 0.3s linear;
}
header.glitch::after {
    color: rgb(94, 255, 0); /* Changed from blue to green */
    left: 3px;  /* Added horizontal offset */
    animation: glitchFade 0.3s linear alternate;
}

@keyframes glitchFade {
    0% { opacity: 0; }
    20% { opacity: 0.7; }
    50% { opacity: 0.3; }
    100% { opacity: 0; }
}

@keyframes glitch {
    0% {
        clip: rect(10px, 9999px, 30px, 0);
        transform: translate(0);
    }
    20% {
        clip: rect(5px, 9999px, 25px, 0);
        transform: translate(0);
    }
    40% {
        clip: rect(15px, 9999px, 35px, 0);
        transform: translate(0);
    }
    60% {
        clip: rect(0px, 9999px, 20px, 0);
        transform: translate(0);
    }
    80% {
        clip: rect(10px, 9999px, 30px, 0);
        transform: translate(0);
    }
    100% {
        clip: rect(5px, 9999px, 25px, 0);
        transform: translate(0);
    }
    
}
@keyframes fadeInOut {
    0% { opacity: 0; transform: scale(0.3); }
    15% { opacity: 1; transform: scale(1); }
    85% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(0.3); }
}

.white-rabbit {
    z-index: 1000;
    user-select: none;
    transition: all 0.3s ease;
}

.white-rabbit:hover {
    transform: scale(1.2);
}

.white-rabbit.running {
    z-index: 1000;
    user-select: none;
    font-size: 2em;
    transition: none;
}

.matrix-hole {
    width: 30px;
    height: 30px;
    background: #000;
    border: 2px solid #0F0;
    border-radius: 50%;
    z-index: 999;
    cursor: pointer;
    animation: glowHole 1.5s infinite alternate;
}

@keyframes glowHole {
    from { box-shadow: 0 0 5px #0F0; }
    to { box-shadow: 0 0 15px #0F0; }
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.section {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #ff0000;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.3);
    font-size: 1.2em; /* Added increased font size */
}

.section h2 {
    color: #ff0000;
    font-size: 1.5em;
    margin-bottom: 20px;
    text-transform: uppercase;
}
.section a{
    color: #ff0000;
    font-size: 1.3em;
    margin-bottom: 20px;
    text-transform: uppercase;
}
.section a:visited {
    color: #ff0000;
    font-size: 1.3em;
    margin-bottom: 20px;
    text-transform: uppercase;
}
.quote {
    font-style: italic;
    color: #fff;
    margin: 15px 0;
    padding: 10px;
    border-left: 3px solid #ff0000;
}

footer {
    text-align: center;
    padding: 20px;
    background: #111;
    color: #ff0000;
    border-top: 2px solid #ff0000;
}

/* Custom pixel cursor for retro feel */
* {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16"><rect x="0" y="0" width="16" height="16" fill="%2300ff00"/></svg>') 8 8, auto !important;
}

/* CRT screen overlay */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.35),
        rgba(0, 0, 0, 0.35) 1px,
        transparent 1px,
        transparent 3px
    );
    pointer-events: none;
    z-index: 9999;
}

/* Background matrix effect canvas */
#matrix-rain {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.typing-text {
    border-right: 0.15em solid #00ff00;
    white-space: nowrap;
    overflow: hidden;
    margin: 0 auto;
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: #00ff00 }
}

/* Add quote overlay style */
.quote-overlay {
    position: fixed;
    padding: 20px;
    background: rgba(0, 0, 0, 0.9);
    color: #0F0;
    border: 2px solid #0F0;
    border-radius: 5px;
    font-family: 'VT323', monospace;
    z-index: 1000;
    max-width: 300px;
    text-align: center;
    transform: translate(-50%, -50%);
    animation: fadeIn 0.5s forwards;
}

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

.project-container {
    position: relative;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 0px;
    width: 100%;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}


.project-card {
    aspect-ratio: 1;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #ff0000;
    border-radius: 5px;
    padding: 10px;
    text-align: center;
    box-shadow: 0 0 10px rgba(255, 0, 0, 0.5);
}

.project-card img {
    width: 100%;
    height: 100%;
    border-radius: 5px;
}

.project-card {
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: scale(1.05);
}

.project-info {
    position: absolute;
    bottom: -100%;
    left: 0;
    width: 90%;
    background: rgba(0, 0, 0, 0.9);
    padding: 10px;
    color: #00ff00;
    transition: bottom 0.3s ease;
}

.project-card:hover .project-info {
    bottom: 0;
}

.project-info h3 {
    margin: 0;
    font-size: 1.2em;
    color: #ff0000;
}

.project-info p {
    margin: 5px 0;
    font-size: 0.9em;
}

.binary-puzzle {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    border: none;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

.binary-puzzle h3 {
    color: #0F0;
    font-size: 2em;
    margin-bottom: 40px;
    text-shadow: 0 0 10px #0F0;
    animation: glow 1.5s ease-in-out infinite alternate;
}

.binary-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
    margin: 20px 0;
    max-width: 400px;
}

.binary-bit {
    background: #000;
    border: 2px solid #0F0;
    padding: 20px;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.binary-bit:hover {
    background: #0F0;
    color: #000;
    box-shadow: 0 0 20px #0F0;
    transform: scale(1.1);
}

.binary-bit.selected {
    background: #0F0;
    color: #000;
    box-shadow: 0 0 30px #0F0;
    transform: scale(1.05);
}

.current-value {
    color: #0F0;
    font-size: 1.5em;
    margin-top: 30px;
    text-shadow: 0 0 5px #0F0;
}

@keyframes glow {
    from {
        text-shadow: 0 0 5px #0F0, 0 0 10px #0F0, 0 0 15px #0F0;
    }
    to {
        text-shadow: 0 0 10px #0F0, 0 0 20px #0F0, 0 0 30px #0F0;
    }
}

.content-wrapper {
    display: none;
}

.content-wrapper.visible {
    display: block;
}

.binary-puzzle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.95);
    border: 2px solid #0F0;
    padding: 20px;
    z-index: 2;
    text-align: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.binary-puzzle.solved {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.binary-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    margin: 20px 0;
}

.binary-bit {
    background: #000;
    border: 1px solid #0F0;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.binary-bit:hover {
    background: #0F0;
    color: #000;
}

.binary-bit.selected {
    background: #0F0;
    color: #000;
}
