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

:root {
    --neon-green: #30bb1a;
    --dark-green: #008f11;
    --matrix-bg: #030a03;
    --hud-border: rgba(46, 161, 28, 0.4);
    --hud-bg: rgba(0, 20, 5, 0.7);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Share Tech Mono', monospace;
    background-color: var(--matrix-bg);
    margin: 0;
    overflow: hidden;
    color: var(--neon-green);
}

/* Typography */
h1, h2, h3 {
    font-family: 'Rajdhani', sans-serif;
    text-transform: uppercase;
}

.text-glow {
    text-shadow: 0 0 5px var(--neon-green), 0 0 10px var(--neon-green), 0 0 20px var(--dark-green);
}

/* Background Canvas */
#matrix-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.15;
    pointer-events: none;
}

/* Cybernetic Grid Background */
.cyber-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: 
        linear-gradient(to right, rgba(46,161,28,0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(46,161,28,0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: 0;
    transform: perspective(500px) rotateX(60deg) translateY(-100px) translateZ(-200px);
    animation: gridMove 20s linear infinite;
    pointer-events: none;
}

@keyframes gridMove {
    0% { background-position: 0 0; }
    100% { background-position: 0 500px; }
}

/* Cybernetic Panels (HUD) */
.hud-panel {
    position: relative;
    background: var(--hud-bg);
    border: 1px solid var(--hud-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: inset 0 0 20px rgba(46, 161, 28, 0.1), 0 0 15px rgba(46, 161, 28, 0.2);
    /* Sci-fi cut corners */
    clip-path: polygon(
        15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%, 0 15px
    );
    transition: all 0.3s ease;
}

.hud-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 2px solid transparent;
    background: linear-gradient(45deg, transparent 40%, var(--neon-green) 45%, transparent 50%) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 10;
    opacity: 0.5;
}

.hud-panel:hover {
    box-shadow: inset 0 0 30px rgba(46, 161, 28, 0.2), 0 0 25px rgba(46, 161, 28, 0.4);
    border-color: var(--neon-green);
}

/* Corner Accents */
.corner-tl, .corner-tr, .corner-bl, .corner-br {
    position: absolute;
    width: 10px;
    height: 10px;
    border-color: var(--neon-green);
    border-style: solid;
    pointer-events: none;
    z-index: 20;
}

.corner-tl { top: -1px; left: -1px; border-width: 2px 0 0 2px; }
.corner-tr { top: -1px; right: -1px; border-width: 2px 2px 0 0; }
.corner-bl { bottom: -1px; left: -1px; border-width: 0 0 2px 2px; }
.corner-br { bottom: -1px; right: -1px; border-width: 0 2px 2px 0; }

/* Image Container Frame */
.image-frame {
    position: relative;
    padding: 10px;
    background: repeating-linear-gradient(
        45deg,
        rgba(0,0,0,0) 0px,
        rgba(0,0,0,0) 10px,
        rgba(46,161,28,0.05) 10px,
        rgba(46,161,28,0.05) 20px
    );
    border: 1px solid var(--neon-green);
    box-shadow: 0 0 30px rgba(46, 161, 28, 0.15);
    clip-path: polygon(30px 0, 100% 0, 100% calc(100% - 30px), calc(100% - 30px) 100%, 0 100%, 0 30px);
}

.image-frame::after {
    content: '';
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 50px rgba(0,0,0,1);
    pointer-events: none;
    z-index: 5;
}

/* Scanning Line Effect */
.scan-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--neon-green);
    box-shadow: 0 0 15px var(--neon-green);
    opacity: 0.7;
    animation: scan 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 30;
}

@keyframes scan {
    0% { top: -5%; opacity: 0; }
    10% { opacity: 1; }
    45% { top: 105%; opacity: 1; }
    50% { opacity: 0; }
    100% { top: 105%; opacity: 0; }
}

/* CRT Scanlines Overlay */
.crt-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0),
        rgba(255,255,255,0) 50%,
        rgba(0,0,0,0.2) 50%,
        rgba(0,0,0,0.2)
    );
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 9999;
}

/* Animations */
.bull-idle {
    animation: pulse-brightness 4s infinite alternate;
}

@keyframes pulse-brightness {
    0% { filter: contrast(110%) saturate(120%) brightness(0.9); }
    100% { filter: contrast(130%) saturate(150%) brightness(1.1); }
}

.flicker {
    animation: flicker 3s linear infinite;
}

@keyframes flicker {
    0%, 19.999%, 22%, 62.999%, 64%, 64.999%, 70%, 100% { opacity: 1; }
    20%, 21.999%, 63%, 63.999%, 65%, 69.999% { opacity: 0.3; }
}

.spin-slow {
    animation: spin 10s linear infinite;
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}

/* Glitch Button */
.glitch-btn {
    position: relative;
    background: transparent;
    color: var(--neon-green);
    border: 1px solid var(--neon-green);
    padding: 8px 16px;
    text-transform: uppercase;
    font-weight: bold;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.2s;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
}

.glitch-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(46, 161, 28, 0.2);
    transform: skewX(-45deg);
    transition: all 0.5s;
}

.glitch-btn:hover {
    background: rgba(46, 161, 28, 0.1);
    box-shadow: 0 0 15px rgba(46, 161, 28, 0.5);
    text-shadow: 0 0 5px var(--neon-green);
}

.glitch-btn:hover::before {
    left: 100%;
}

/* Holders Animation */
.holder-entry {
    animation: slideInRight 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    opacity: 0;
    transform: translateX(30px);
}

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

/* Progress bar */
.progress-bar-container {
    width: 100%;
    height: 4px;
    background: rgba(46, 161, 28, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--neon-green);
    width: 0%;
    box-shadow: 0 0 10px var(--neon-green);
    transition: width 1s linear;
}

/* Button Glitch */
.glitch-btn {
    animation: btn-flicker 4s infinite;
}
@keyframes btn-flicker {
    0%, 95%, 100% { transform: translate(0, 0); opacity: 1; filter: none; }
    96% { transform: translate(2px, -2px); opacity: 0.8; filter: hue-rotate(90deg); }
    97% { transform: translate(-2px, 2px); opacity: 1; filter: contrast(200%); }
    98% { transform: translate(2px, 2px); opacity: 0.9; filter: invert(1); }
    99% { transform: translate(-2px, -2px); opacity: 1; filter: none; }
}

/* Hide Scrollbar */
::-webkit-scrollbar {
    width: 0px;
}

/* Glitch Text Effect */
.glitch-text { position: relative; }
.glitch-text::before, .glitch-text::after { content: attr(data-text); position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
.glitch-text::before { left: 2px; text-shadow: -1px 0 red; clip: rect(44px, 450px, 56px, 0); animation: glitch-anim-1 5s infinite linear alternate-reverse; }
.glitch-text::after { left: -2px; text-shadow: -1px 0 blue; clip: rect(44px, 450px, 56px, 0); animation: glitch-anim-2 5s infinite linear alternate-reverse; }
@keyframes glitch-anim-1 { 0% { clip: rect(10px, 9999px, 83px, 0); } 20% { clip: rect(42px, 9999px, 11px, 0); } 40% { clip: rect(66px, 9999px, 2px, 0); } 60% { clip: rect(15px, 9999px, 48px, 0); } 80% { clip: rect(98px, 9999px, 33px, 0); } 100% { clip: rect(2px, 9999px, 66px, 0); } }
@keyframes glitch-anim-2 { 0% { clip: rect(83px, 9999px, 10px, 0); } 20% { clip: rect(11px, 9999px, 42px, 0); } 40% { clip: rect(2px, 9999px, 66px, 0); } 60% { clip: rect(48px, 9999px, 15px, 0); } 80% { clip: rect(33px, 9999px, 98px, 0); } 100% { clip: rect(66px, 9999px, 2px, 0); } }
