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

:root {
    --bg: #0a0a0a;
    --bg-secondary: #111;
    --text: #e0e0e0;
    --text-muted: #888;
    --accent: #00ff88;
    --accent-dim: #00cc6a;
    --bracket: #666;
    --code-bg: #1a1a1a;
}

html {
    font-size: 16px;
}

body {
    font-family: 'SF Mono', 'Fira Code', 'JetBrains Mono', 'Cascadia Code', Consolas, monospace;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

main {
    max-width: 800px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 6rem;
}

.title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.squiggly {
    position: relative;
    display: inline-block;
    text-decoration: none;
}

.squiggly::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -8px;
    height: 8px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 4'%3E%3Cpath fill='none' stroke='%2300ff88' stroke-width='1.5' d='M0 3c5 0 5-2 10-2s5 2 10 2 5-2 10-2'/%3E%3C/svg%3E") repeat-x;
    background-size: 20px 4px;
    animation: squiggle 0.5s linear infinite;
}

@keyframes squiggle {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 20px 0;
    }
}

.tagline {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.github-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text);
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border: 1px solid #333;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.github-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.github-link svg {
    flex-shrink: 0;
}

/* Feature Sections */
.feature {
    margin-bottom: 5rem;
    padding: 2rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid #222;
}

.feature-header {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    flex-wrap: wrap;
}

.bracket {
    color: var(--bracket);
}

.arrow {
    color: var(--text-muted);
    margin: 0 0.5rem;
}

.animated-word {
    color: var(--accent);
    min-width: 80px;
    display: inline-block;
    text-align: center;
    transition: opacity 0.3s ease;
}

.animated-word.fade {
    opacity: 0;
}

.feature-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Terminal Styles */
.terminal {
    background: #0d0d0d;
    border: 1px solid #333;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.terminal-header {
    background: #1a1a1a;
    padding: 0.6rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid #333;
}

.terminal-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.terminal-dot.red { background: #ff5f56; }
.terminal-dot.yellow { background: #ffbd2e; }
.terminal-dot.green { background: #27c93f; }

.terminal-title {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-left: auto;
    margin-right: auto;
}

.terminal-body {
    padding: 1rem;
    min-height: 180px;
    font-size: 0.85rem;
    line-height: 1.6;
}

.terminal-line {
    display: block;
    white-space: pre-wrap;
    word-break: break-all;
}

.terminal-prompt {
    color: var(--accent);
}

.terminal-command {
    color: var(--text);
}

.terminal-output {
    color: var(--text-muted);
}

.terminal-success {
    color: var(--accent);
}

.terminal-cursor {
    display: inline-block;
    width: 8px;
    height: 1.1em;
    background: var(--accent);
    animation: blink 1s step-end infinite;
    vertical-align: text-bottom;
    margin-left: 2px;
}

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

.coming-soon-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 255, 136, 0.1);
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    z-index: 10;
}

/* Split Terminal Layout */
.terminal-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    position: relative;
}

.terminal-wrapper {
    position: relative;
}

.machine-label {
    position: absolute;
    top: -0.5rem;
    left: 1rem;
    background: var(--bg-secondary);
    color: var(--text-muted);
    font-size: 0.7rem;
    padding: 0.1rem 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 5;
}

.terminal-split .terminal-body {
    min-height: 200px;
    font-size: 0.75rem;
}

.e2e-note {
    color: var(--accent-dim) !important;
    font-size: 0.85rem;
    font-style: italic;
    margin-top: 0.5rem;
}

.terminal-link {
    color: #6ea8fe;
    text-decoration: underline;
}

.instructions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.instructions p {
    color: var(--text-muted);
}

.instructions code {
    background: var(--code-bg);
    color: var(--accent);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.95rem;
}

/* Install Section */
.install {
    margin-bottom: 4rem;
}

.install h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.install-methods {
    display: grid;
    gap: 1.5rem;
}

.install-method {
    background: var(--bg-secondary);
    border: 1px solid #222;
    border-radius: 8px;
    padding: 1.5rem;
}

.install-method h3 {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-weight: 500;
}

.install-method pre {
    background: var(--code-bg);
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
}

.install-method code {
    color: var(--accent);
    font-size: 0.9rem;
    line-height: 1.8;
}

/* Self-host Section */
.self-host {
    margin-bottom: 4rem;
    text-align: center;
}

.self-host h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.self-host-desc {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.self-host .github-link {
    margin-bottom: 1.5rem;
}

.self-host-usage {
    margin-top: 1.5rem;
    background: var(--bg-secondary);
    border: 1px solid #222;
    border-radius: 8px;
    padding: 1.5rem;
    text-align: left;
}

.self-host-usage > p:first-child {
    color: var(--text-muted);
    margin-bottom: 1rem;
    text-align: center;
}

.self-host-usage pre {
    background: var(--code-bg);
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
}

.self-host-usage code {
    color: var(--accent);
    font-size: 0.9rem;
    line-height: 1.8;
}

.easy-peasy {
    color: var(--text-muted);
    font-style: italic;
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9rem;
}

/* Footer */
footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #222;
    color: var(--text-muted);
}

footer a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: var(--accent);
}

.separator {
    margin: 0 0.75rem;
}

/* Responsive */
@media (max-width: 700px) {
    .terminal-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    main {
        padding: 2rem 1rem;
    }

    .title {
        font-size: 2.5rem;
    }

    .feature-header {
        font-size: 1rem;
        flex-wrap: nowrap;
    }

    .animated-word {
        min-width: 40px;
    }

    .arrow {
        margin: 0 0.25rem;
    }

    .install-method pre {
        padding: 0.75rem;
    }

    .install-method code {
        font-size: 0.8rem;
        white-space: pre-wrap;
        word-break: break-all;
    }

    .self-host .github-link {
        font-size: 0.8rem;
    }

}

/* Vim Toggle */
.vim-toggle {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 100;
}

.vim-toggle-label {
    color: #555;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.vim-toggle-btn {
    width: 36px;
    height: 20px;
    background: #333;
    border: 1px solid #444;
    border-radius: 10px;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
}

.vim-toggle-btn:hover {
    border-color: #555;
}

.vim-toggle-indicator {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    background: #666;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.vim-toggle.enabled .vim-toggle-btn {
    background: rgba(144, 238, 144, 0.15);
    border-color: #5a8a5a;
}

.vim-toggle.enabled .vim-toggle-indicator {
    left: 18px;
    background: #7ab87a;
}

.vim-toggle.enabled .vim-toggle-label {
    color: #7ab87a;
}

@media (max-width: 768px) {
    .vim-toggle {
        display: none;
    }
}
