/* ================================================
   chagrAI - Cyberpunk Minimalista
   Artesanal Intelligence Interface
   ================================================ */

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

body {
    background: #000000;
    color: #00FF41;
    font-family: 'Share Tech Mono', 'Courier New', monospace;
    font-size: 16px;
    line-height: 1.4;
    overflow: hidden;
    height: 100vh;
}

/* ================================================
   Landing Page Styles
   ================================================ */
.landing-container {
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 10;
}

.floating-text-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
    pointer-events: none;
}

.floating-text {
    position: absolute;
    color: #00FF41;
    opacity: 0.3;
    font-size: 14px;
    white-space: nowrap;
    animation: floatLeftToRight 8s linear infinite;
}

.floating-text.reverse {
    animation: floatRightToLeft 6s linear infinite;
}

@keyframes floatLeftToRight {
    0% {
        transform: translateX(-200px);
    }
    100% {
        transform: translateX(calc(100vw + 200px));
    }
}

@keyframes floatRightToLeft {
    0% {
        transform: translateX(calc(100vw + 200px));
    }
    100% {
        transform: translateX(-200px);
    }
}

.main-content {
    text-align: center;
    z-index: 20;
    background: rgba(0, 0, 0, 0.8);
    padding: 60px 40px;
    border: 2px solid #00FF41;
    backdrop-filter: blur(10px);
}

.logo {
    font-size: clamp(4rem, 10vw, 8rem);
    font-weight: bold;
    margin-bottom: 20px;
    color: #00FF41;
    text-shadow: 0 0 20px #00FF41;
    animation: logoGlow 2s ease-in-out infinite alternate;
}

@keyframes logoGlow {
    from {
        text-shadow: 0 0 20px #00FF41;
    }
    to {
        text-shadow: 0 0 30px #00FF41, 0 0 40px #00FF41;
    }
}

.subtitle {
    font-size: clamp(1.2rem, 3vw, 2rem);
    margin-bottom: 40px;
    opacity: 0.9;
    letter-spacing: 3px;
}

.try-now-btn {
    background: transparent;
    border: 2px solid #00FF41;
    color: #00FF41;
    font-family: 'Share Tech Mono', monospace;
    font-size: 18px;
    font-weight: bold;
    padding: 15px 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    overflow: hidden;
}

.try-now-btn:hover {
    background: #00FF41;
    color: #000000;
    box-shadow: 0 0 20px #00FF41;
    transform: translateY(-2px);
}

.try-now-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #00FF41;
    transition: left 0.5s;
    z-index: -1;
}

.try-now-btn:hover::before {
    left: 0;
}

/* ================================================
   Terminal Styles
   ================================================ */
.terminal-container {
    width: 100%;
    height: 100vh;
    padding: 20px;
    display: none;
    flex-direction: column;
    max-width: 1200px;
    margin: 0 auto;
}

.terminal-header {
    margin-bottom: 20px;
    font-weight: bold;
    opacity: 0.8;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.terminal-title {
    color: #00FF41;
}

.back-btn {
    background: transparent;
    border: 1px solid #00FF41;
    color: #00FF41;
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    padding: 5px 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.back-btn:hover {
    background: #00FF41;
    color: #000000;
}

.terminal-output {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 20px;
    scrollbar-width: thin;
    scrollbar-color: #00FF41 #000000;
}

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

.terminal-output::-webkit-scrollbar-track {
    background: #000000;
}

.terminal-output::-webkit-scrollbar-thumb {
    background: #00FF41;
    border-radius: 4px;
}

.terminal-line {
    margin-bottom: 8px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.terminal-line.user-input {
    color: #00FF41;
}

.terminal-line.ai-response {
    color: #00FF41;
    margin-left: 20px;
    opacity: 0.9;
}

.terminal-line.system {
    color: #00FF41;
    opacity: 0.7;
}

.terminal-line.error {
    color: #FF4444;
    opacity: 0.8;
}

.prompt {
    color: #00FF41;
    font-weight: bold;
    margin-right: 5px;
}

.terminal-input-container {
    display: flex;
    align-items: center;
    border-top: 1px solid #003300;
    padding-top: 10px;
}

.terminal-input {
    background: transparent;
    border: none;
    color: #00FF41;
    font-family: 'Share Tech Mono', 'Courier New', monospace;
    font-size: 16px;
    outline: none;
    flex: 1;
    margin-left: 5px;
    margin-right: 5px;
}

.terminal-input::placeholder {
    color: #004400;
    opacity: 0.5;
}

.terminal-input:focus {
    outline: none;
    background: rgba(0, 255, 65, 0.02);
}

/* ================================================
   Cursor Animation
   ================================================ */
.cursor,
.input-cursor {
    animation: blink 1s infinite;
    font-weight: bold;
}

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

/* ================================================
   Typing Effect
   ================================================ */
.typing {
    border-right: 2px solid #00FF41;
    animation: typewriter 0.05s steps(1) infinite;
}

@keyframes typewriter {
    from { border-color: #00FF41; }
    to { border-color: transparent; }
}

/* ================================================
   Loading Animation
   ================================================ */
.loading-dots {
    display: inline-block;
}

.loading-dots::after {
    content: '';
    animation: loadingDots 1.5s infinite;
}

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

/* ================================================
   Responsive Design
   ================================================ */
@media (max-width: 768px) {
    .main-content {
        padding: 40px 20px;
        margin: 20px;
    }
    
    .try-now-btn {
        padding: 12px 24px;
        font-size: 16px;
    }
    
    .terminal-container {
        padding: 15px;
    }
    
    .terminal-input {
        font-size: 14px;
    }
    
    body {
        font-size: 14px;
    }
    
    .terminal-line {
        margin-bottom: 6px;
    }
}

@media (max-width: 480px) {
    .main-content {
        padding: 30px 15px;
        margin: 15px;
    }
    
    .try-now-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .logo {
        font-size: 3rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    body {
        font-size: 12px;
    }
    
    .terminal-container {
        padding: 10px;
    }
    
    .terminal-input {
        font-size: 12px;
    }
    
    .terminal-header {
        margin-bottom: 15px;
    }
}

/* ================================================
   Utilities
   ================================================ */
.hidden {
    display: none !important;
}

::selection {
    background: #003300;
    color: #00FF41;
}

::-moz-selection {
    background: #003300;
    color: #00FF41;
}

/* ================================================
   Accessibility
   ================================================ */
@media (prefers-reduced-motion: reduce) {
    .cursor,
    .input-cursor,
    .typing {
        animation: none;
    }
    
    .cursor,
    .input-cursor {
        opacity: 1;
    }
    
    .logo {
        animation: none;
    }
    
    .floating-text {
        animation: none;
    }
}

/* ================================================
   Print Styles
   ================================================ */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .cursor,
    .input-cursor {
        display: none;
    }
    
    .floating-text-bg {
        display: none;
    }
}