/* ==========================================
   CYBERPUNK TERMINAL PAGE
   Fatih Elbeyoğlu - Yapım Aşamasında
   ========================================== */

:root {
    /* Core Colors - Cyberpunk Palette */
    --bg-primary: #0a0e17;
    --bg-secondary: #0f1623;
    --bg-tertiary: #151d2e;
    --bg-card: rgba(15, 22, 35, 0.95);
    --bg-card-border: rgba(100, 200, 255, 0.25);

    /* Neon Accent Colors */
    --neon-cyan: #4187ad;
    --neon-blue: #4a9eff;
    --neon-purple: #b347ff;
    --neon-pink: #ff6b9d;
    --neon-green: #2fa819;
    --neon-orange: #ff8c42;
    --neon-yellow: #ffd93d;

    /* Text Colors */
    --text-primary: #e8f4f8;
    --text-secondary: #9db4c0;
    --text-muted: #5a7184;

    /* Glows */
    --glow-cyan: 0 0 20px rgba(100, 200, 255, 0.5), 0 0 40px rgba(100, 200, 255, 0.3);
    --glow-green: 0 0 15px rgba(74, 222, 128, 0.4);
    --glow-blue: 0 0 20px rgba(74, 158, 255, 0.4);

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 30px;
}

/* ==========================================
   RESET & BASE
   ========================================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'JetBrains Mono', monospace;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}

/* ==========================================
   NETWORK BACKGROUND ANIMATION
   ========================================== */
.network-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

#networkCanvas {
    width: 100%;
    height: 100%;
}

/* Grid Overlay */
.grid-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(100, 200, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(100, 200, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: 1;
    pointer-events: none;
}

/* Scanline Effect */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.1) 2px,
            rgba(0, 0, 0, 0.1) 4px);
    z-index: 9999;
    pointer-events: none;
    opacity: 0.3;
}

/* ==========================================
   MAIN LAYOUT
   ========================================== */
.wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 18px;
    position: relative;
    z-index: 10;
    width: 100%;
}

/* ==========================================
   TERMINAL WINDOW (Main Container)
   ========================================== */
.terminal-window {
    width: min(900px, 95%);
    max-width: 900px;
    margin: 0 auto;
    /*background: var(--bg-card);*/
    border: 1px solid var(--bg-card-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.5),
        var(--glow-cyan),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: cardGlow 3s ease-in-out infinite alternate, fadeIn 0.8s ease-out;
    opacity: 0;
    animation-fill-mode: forwards;
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    min-height: 400px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes cardGlow {
    from {
        box-shadow: 
            0 20px 60px rgba(0, 0, 0, 0.5),
            0 0 30px rgba(100, 200, 255, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.05);
    }
    to {
        box-shadow: 
            0 20px 60px rgba(0, 0, 0, 0.5),
            0 0 60px rgba(100, 200, 255, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.05);
    }
}

/* ==========================================
   TERMINAL HEADER
   ========================================== */
.terminal-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(100, 200, 255, 0.15);
    font-family: 'JetBrains Mono', monospace;
    position: relative;
}

.terminal-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(100, 200, 255, 0.3), transparent);
}

.terminal-buttons {
    display: flex;
    gap: 8px;
}

.terminal-btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition-fast);
}

.terminal-btn.red {
    background: #ff5f57;
}

.terminal-btn.yellow {
    background: #febc2e;
}

.terminal-btn.green {
    background: #28c840;
}

.terminal-btn:hover {
    opacity: 0.8;
    transform: scale(1.1);
}

.terminal-title-main {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    justify-content: center;
    padding: 0 20px;
}

.terminal-prompt {
    color: var(--neon-cyan);
    font-weight: 700;
    font-size: 16px;
    text-shadow: var(--glow-cyan);
    letter-spacing: 1px;
}

.terminal-domain {
    color: var(--neon-cyan);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.5px;
    text-shadow: 0 0 10px rgba(100, 200, 255, 0.3);
    transition: var(--transition-normal);
}

.terminal-domain:hover {
    text-shadow: var(--glow-cyan);
    transform: scale(1.02);
}

.terminal-cursor-header {
    display: inline-block;
    width: 2px;
    height: 18px;
    background: var(--neon-cyan);
    animation: blink 1s infinite;
    margin-left: 4px;
    box-shadow: 0 0 8px rgba(100, 200, 255, 0.6);
}

.terminal-header .terminal-title {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    flex: 1;
    display: none; /* Hide old title */
}

.terminal-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    flex-shrink: 0;
    white-space: nowrap;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-dot.online {
    background: var(--neon-green);
    box-shadow: var(--glow-green);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

/* ==========================================
   TERMINAL BODY
   ========================================== */
.terminal-body {
    padding: 24px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    line-height: 1.8;
    min-height: 0;
    background: rgba(0, 0, 0, 0.2);
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-y: auto;
    flex: 1;
    display: block;
}

.terminal-line {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 4px;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    flex-wrap: wrap;
}

/* Terminal Prompts */
.prompt {
    color: var(--neon-green);
    font-weight: 700;
    flex-shrink: 0;
}

.prompt-user {
    color: var(--neon-green);
    font-weight: 700;
}

.prompt-host {
    color: var(--text-secondary);
    font-weight: 400;
    opacity: 0.8;
}

/* Commands */
.command {
    color: var(--text-muted);
    opacity: 0.7;
    font-weight: 500;
}

/* Output Types */
.output {
    color: var(--text-primary);
    font-weight: 400;
}

.output-info {
    color: var(--text-primary);
    font-weight: 400;
}

.output-success {
    color: var(--neon-green);
    font-weight: 600;
}

.output-highlight {
    color: var(--neon-cyan);
    font-weight: 600;
}

.output-muted {
    color: var(--text-secondary);
    font-weight: 400;
}

.output-label {
    color: var(--neon-cyan);
    font-weight: 600;
    min-width: 80px;
}

.output-link {
    color: var(--neon-cyan);
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition-fast);
    border-bottom: 1px solid transparent;
    word-break: break-all;
    overflow-wrap: break-word;
}

.output-link:hover {
    color: var(--neon-blue);
    border-bottom-color: var(--neon-blue);
}

#copyEmail {
    cursor: pointer;
}

.password-dots {
    color: var(--neon-cyan);
    letter-spacing: 2px;
    font-weight: 600;
}

/* Success Badge */
.success-badge {
    background: rgba(74, 222, 128, 0.15);
    color: var(--neon-green);
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-block;
    margin-right: 8px;
}

/* Cursor */
.cursor-blink {
    display: inline-block;
    width: 8px;
    height: 18px;
    background: var(--neon-cyan);
    animation: blink 1s infinite;
    vertical-align: middle;
    margin-left: 2px;
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

/* ==========================================
   TOAST NOTIFICATION
   ========================================== */
.toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%);
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(100, 200, 255, 0.3);
    background: rgba(15, 22, 35, 0.95);
    color: var(--text-primary);
    font-size: 14px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), var(--glow-cyan);
    z-index: 9999;
    max-width: min(92vw, 640px);
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(10px);
    font-family: 'JetBrains Mono', monospace;
}

.toast.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-4px);
}

/* ==========================================
   TERMINAL FOOTER
   ========================================== */
.terminal-footer {
    padding: 18px 24px;
    border-top: 1px solid rgba(100, 200, 255, 0.15);
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.3) 100%);
    font-family: 'JetBrains Mono', monospace;
    position: relative;
}

.terminal-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(100, 200, 255, 0.3), transparent);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.footer-text {
    color: var(--text-muted);
}

.footer-separator {
    color: var(--text-muted);
    opacity: 0.3;
}

.footer-version {
    color: var(--neon-cyan);
    font-weight: 600;
}

.footer-right {
    display: flex;
    align-items: center;
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-icon {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(100, 200, 255, 0.25);
    border-radius: var(--radius-sm);
    background: rgba(100, 200, 255, 0.05);
    color: var(--neon-cyan);
    text-decoration: none;
    font-size: 13px;
    transition: background-color var(--transition-normal), border-color var(--transition-normal), color var(--transition-normal);
}

.footer-icon:hover {
    background: rgba(100, 200, 255, 0.15);
    border-color: rgba(100, 200, 255, 0.4);
    color: var(--text-primary);
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }

    .wrap {
        padding: 20px 12px;
        align-items: center;
        justify-content: center;
        min-height: 100vh;
    }

    .terminal-window {
        width: 100%;
        max-width: 100%;
        border-radius: var(--radius-md);
        max-height: calc(100vh - 40px);
        min-height: 300px;
    }

    .terminal-body {
        padding: 14px 12px;
        font-size: 0.8rem;
        min-height: 0;
        line-height: 1.6;
        display: block;
    }

    .terminal-line {
        font-size: 0.8rem;
        margin-bottom: 4px;
        word-break: break-word;
        overflow-wrap: break-word;
    }

    .terminal-header {
        padding: 10px 12px;
        gap: 6px;
        flex-wrap: nowrap;
        justify-content: space-between;
    }

    .terminal-buttons {
        gap: 5px;
        flex-shrink: 0;
    }

    .terminal-btn {
        width: 9px;
        height: 9px;
    }

    .terminal-title-main {
        flex: 1;
        min-width: 0;
        padding: 0 6px;
        gap: 3px;
        justify-content: center;
        overflow: visible;
    }

    .terminal-prompt {
        font-size: 10px;
        letter-spacing: 0.2px;
        flex-shrink: 0;
    }

    .terminal-domain {
        font-size: 8.5px;
        letter-spacing: 0.1px;
        white-space: nowrap;
        overflow: visible;
        text-overflow: clip;
        flex-shrink: 1;
        min-width: 0;
    }

    .terminal-cursor-header {
        width: 1.5px;
        height: 11px;
        margin-left: 2px;
        flex-shrink: 0;
    }

    .terminal-status {
        display: flex !important;
        gap: 3px;
        font-size: 7px;
        flex-shrink: 0;
        white-space: nowrap;
        letter-spacing: 0.3px;
    }

    .status-dot {
        width: 5px;
        height: 5px;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 14px;
    }

    .terminal-footer {
        padding: 12px 14px;
    }

    .footer-left {
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px;
        font-size: 0.7rem;
    }

    .footer-social {
        justify-content: center;
        gap: 12px;
    }

    .footer-icon {
        width: 38px;
        height: 38px;
        font-size: 15px;
        min-width: 38px;
    }

    .output-label {
        min-width: 70px;
        font-size: 0.75rem;
    }

    .toast {
        bottom: 16px;
        padding: 12px 16px;
        font-size: 13px;
        max-width: calc(100vw - 32px);
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .wrap {
        padding: 16px 10px;
        align-items: center;
        justify-content: center;
        min-height: 100vh;
    }

    .terminal-window {
        border-radius: var(--radius-sm);
        max-height: calc(100vh - 32px);
        min-height: 250px;
    }

    .terminal-body {
        padding: 12px 10px;
        font-size: 0.75rem;
        min-height: 0;
        line-height: 1.5;
        display: block;
    }

    .terminal-line {
        font-size: 0.75rem;
        gap: 4px;
        margin-bottom: 3px;
    }

    .terminal-header {
        padding: 8px 10px;
        gap: 5px;
        justify-content: space-between;
    }

    .terminal-buttons {
        gap: 4px;
        flex-shrink: 0;
    }

    .terminal-btn {
        width: 8px;
        height: 8px;
    }

    .terminal-title-main {
        padding: 0 4px;
        gap: 2px;
        flex: 1;
        min-width: 0;
        overflow: visible;
    }

    .terminal-prompt {
        font-size: 8px;
        letter-spacing: 0.1px;
    }

    .terminal-domain {
        font-size: 7.5px;
        letter-spacing: 0.05px;
        white-space: nowrap;
        overflow: visible;
        text-overflow: clip;
        flex-shrink: 1;
    }

    .terminal-cursor-header {
        width: 1.5px;
        height: 9px;
        margin-left: 2px;
    }

    .terminal-status {
        display: flex !important;
        gap: 2px;
        font-size: 6px;
        flex-shrink: 0;
        white-space: nowrap;
        letter-spacing: 0.2px;
    }

    .status-dot {
        width: 4px;
        height: 4px;
    }

    .output-label {
        min-width: 60px;
        font-size: 0.7rem;
    }

    .footer-content {
        gap: 12px;
    }

    .terminal-footer {
        padding: 10px 12px;
    }

    .footer-left {
        flex-direction: column;
        gap: 6px;
        font-size: 0.65rem;
    }

    .footer-separator {
        display: none;
    }

    .footer-social {
        gap: 10px;
    }

    .footer-icon {
        width: 36px;
        height: 36px;
        font-size: 14px;
        min-width: 36px;
    }

    .toast {
        bottom: 12px;
        padding: 10px 14px;
        font-size: 12px;
        max-width: calc(100vw - 24px);
    }

    /* Reduce grid overlay size on mobile */
    .grid-overlay {
        background-size: 30px 30px;
    }
}

/* Landscape mobile optimization */
@media (max-width: 768px) and (orientation: landscape) {
    .wrap {
        padding: 12px;
        align-items: center;
    }

    .terminal-body {
        min-height: 0;
        padding: 10px 12px;
        display: block;
    }

    .terminal-header {
        padding: 8px 12px;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .footer-icon {
        min-width: 44px;
        min-height: 44px;
    }

    .terminal-btn {
        min-width: 12px;
        min-height: 12px;
    }

    .output-link {
        padding: 2px 4px;
        margin: -2px -4px;
    }
}
