/**
 * TCL Terminal — Shared styles for the typewriter terminal component
 * Used on: auth page, dashboard, 404, checkout
 */

/* ── Terminal Colors ── */
.t-green {
    color: #10B981;
}

.t-blue {
    color: #3B82F6;
}

.t-gold {
    color: #F59E0B;
}

.t-red {
    color: #EF4444;
}

.t-cyan {
    color: #22D3EE;
}

.t-gray {
    color: #64748b;
}

.t-white {
    color: #e2e8f0;
}

.t-dim {
    color: #475569;
}

/* ── Blinking Cursor ── */
.terminal-cursor {
    animation: tclBlink 1s step-end infinite;
}

@keyframes tclBlink {
    50% {
        opacity: 0;
    }
}

/* ── Terminal Window Shell ── */
.tcl-terminal-window {
    background: #0a0e1a;
    border-radius: 1rem;
    border: 1px solid #1f2937;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Ensure FA icons keep their font inside terminal */
.tcl-terminal-window .fa-solid,
.tcl-terminal-window .fa-regular,
.tcl-terminal-window .fa-brands,
.tcl-terminal-window [class^="fa-"] {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
}

/* Chrome / title bar */
.tcl-terminal-chrome {
    background: #151E32;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid #1f2937;
    flex-shrink: 0;
}

.tcl-terminal-dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
}

/* Body / output area */
.tcl-terminal-body {
    position: relative;
    padding: 1.25rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    line-height: 1.6;
    color: #e2e8f0;
    white-space: pre-wrap;
    overflow-y: auto;
}

/* Scrollbar */
.tcl-terminal-body::-webkit-scrollbar {
    width: 6px;
}

.tcl-terminal-body::-webkit-scrollbar-track {
    background: transparent;
}

.tcl-terminal-body::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 3px;
}

/* Scanlines overlay */
.tcl-terminal-scanlines::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
    background: repeating-linear-gradient(0deg,
            transparent, transparent 2px,
            rgba(0, 0, 0, 0.03) 2px, rgba(0, 0, 0, 0.03) 4px);
}

/* ── Animated Gradient Border (optional) ── */
.tcl-terminal-glow-border {
    position: relative;
}

.tcl-terminal-glow-border::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 1px;
    border-radius: 1rem;
    background: linear-gradient(135deg, #10B981, #3B82F6, #F97316, #10B981);
    background-size: 300% 300%;
    animation: tclBorderMorph 6s ease infinite;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

@keyframes tclBorderMorph {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}