:root {
    --bg-color: #0b0f19;
    --text-color: #e2e8f0;
    --accent-color: #3b82f6;
    --border-color: #1a2639;
    --hover-color: #2563eb;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html, body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-sans);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Typography styles */
h1, h2, h3 {
    font-weight: 700;
    letter-spacing: -0.05em;
    color: white;
}

.text-accent {
    color: var(--accent-color);
}

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

a:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

/* Header Navbar */
.navbar {
    border-bottom: 2px solid var(--border-color);
    padding: 1rem 0;
    background-color: rgba(11, 15, 25, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
}

.brand:hover {
    text-decoration: none;
    color: var(--accent-color);
}

.logo {
    height: 3rem;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--accent-color);
    text-decoration: none;
}

@media (max-width: 600px) {
    .nav-content {
        flex-direction: column;
        gap: 1rem;
    }
    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
    }
}

/* Hero Section */
.hero {
    padding: 4rem 1rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin-bottom: 3rem;
}

.hero-title {
    font-size: 3rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #94a3b8;
    max-width: 600px;
    margin: 0 auto;
}

/* Install Block */
.install-block {
    width: 100%;
    max-width: 900px;
    margin-bottom: 3rem;
    border: 1px solid #1a2639;
    background-color: #050811;
}

.install-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: 1px solid #1a2639;
}

.install-tabs {
    display: flex;
}

.install-tab {
    background: transparent;
    color: #64748b;
    border: none;
    border-right: 1px solid #1a2639;
    border-top: 2px solid transparent;
    padding: 1rem 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    cursor: pointer;
    transition: color 0.2s ease;
}

.install-tab:hover {
    color: var(--text-color);
}

.install-tab.active {
    color: var(--accent-color);
    border-top: 2px solid var(--accent-color);
}

.view-script-link {
    color: #64748b;
    font-size: 0.85rem;
    text-decoration: underline;
    font-family: var(--font-mono);
    margin-right: 1.5rem;
    margin-bottom: 1rem;
    background: none;
    border: none;
    cursor: pointer;
}

.view-script-link:hover {
    color: var(--text-color);
}

.install-cmd {
    display: flex;
    align-items: center;
    padding: 2.5rem 1.5rem;
    justify-content: space-between;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.install-cmd-hidden {
    display: none !important;
}

.install-cmd code {
    flex: 1;
    min-width: 0;
    max-width: 100%;
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--text-color);
    overflow-x: auto;
    margin: 0;
    padding-right: 1rem;
    white-space: pre-wrap;
    word-break: break-all;
    display: block;
}

.copy-btn {
    background-color: transparent;
    color: #64748b;
    border: 1px solid #334155;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.copy-btn:hover {
    border-color: #64748b;
    color: var(--text-color);
}

@media (max-width: 768px) {
    .hero {
        padding: 3rem 1rem 1rem;
    }
    .hero-title {
        font-size: 2.25rem;
    }
    .hero-subtitle {
        font-size: 1.05rem;
    }
    .install-header {
        flex-direction: column;
        align-items: stretch;
    }
    .install-tabs {
        width: 100%;
        display: flex;
        border-bottom: 1px solid #1a2639;
    }
    .install-tab {
        flex: 1;
        text-align: center;
        padding: 0.8rem 1rem;
    }
    .view-script-link {
        align-self: flex-end;
        margin: 0.8rem 1rem 0.8rem 0;
    }
    .install-cmd {
        padding: 1.5rem 1rem;
        align-items: flex-start;
        flex-direction: column;
        gap: 1rem;
        max-width: 100%;
    }
    .install-cmd code {
        width: 100%;
        max-width: 100%;
        padding-right: 0;
        box-sizing: border-box;
        word-break: break-all;
        white-space: pre-wrap;
    }
    .copy-btn {
        align-self: flex-end;
    }
}

/* Preview Image Area */
.hero-preview {
    width: 100%;
    max-width: 1000px;
    margin-top: 2rem;
    border: 3px solid var(--border-color);
}

.preview-image {
    width: 100%;
    height: auto;
    display: block;
    image-rendering: pixelated;
}

/* Features Section */
.features {
    padding: 5rem 0;
    background-color: #050811;
    flex: 1;
    border-top: 2px solid var(--border-color);
    border-bottom: 2px solid var(--border-color);
}

.section-title {
    font-size: 2rem;
    margin-bottom: 3rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: var(--font-mono);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .feature-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .feature-card:nth-child(1) {
        grid-column: span 2;
    }
    
    .feature-card:nth-child(4) {
        grid-column: span 2;
    }
}

.feature-card {
    border: 2px solid var(--border-color);
    padding: 2rem;
    background-color: var(--bg-color);
    transition: transform 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-color);
}

.feature-title {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    font-family: var(--font-mono);
    color: var(--accent-color);
}

.feature-desc {
    color: #94a3b8;
    font-size: 0.95rem;
}

/* Footer Section */
.site-footer {
    padding: 3rem 0;
    margin-top: auto;
    background-color: var(--bg-color);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: #64748b;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: #64748b;
}

.footer-links a:hover {
    color: white;
}

/* Documentation Layout */
.docs-main {
    display: flex;
    flex-direction: column;
    padding: 3rem 1rem;
    gap: 3rem;
}

@media (min-width: 900px) {
    .docs-main {
        flex-direction: row;
        align-items: flex-start;
    }
    
    .docs-sidebar {
        max-width: 250px;
        position: sticky;
        top: 6rem;
    }
}

.docs-sidebar {
    width: 100%;
    position: relative;
    border: 1px solid var(--border-color);
    background-color: #0b0f19;
    padding: 1.5rem;
}

.toc h3 {
    font-family: var(--font-mono);
    color: var(--accent-color);
    margin-bottom: 1rem;
    text-transform: uppercase;
    font-size: 1rem;
    letter-spacing: 0.1em;
}

.toc ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toc a {
    color: #94a3b8;
    font-size: 0.95rem;
}

.toc a:hover {
    color: white;
    text-decoration: none;
}

.docs-content {
    flex: 1;
    max-width: 800px;
}

.docs-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 1rem;
}

.docs-content h2 {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-top: 3rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.docs-content h3 {
    font-size: 1.1rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: white;
}

.docs-content p {
    color: #cbd5e1;
    margin-bottom: 1.25rem;
    line-height: 1.7;
}

.docs-list {
    color: #cbd5e1;
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.docs-list li {
    line-height: 1.5;
}

.docs-content code {
    background-color: #0f172a;
    padding: 0.2em 0.4em;
    font-family: var(--font-mono);
    font-size: 0.9em;
    color: #a5b4fc;
}

.docs-code-block {
    background-color: #050811;
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.docs-code-block code {
    background-color: transparent;
    padding: 0;
    font-size: 0.95rem;
    flex: 1;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-all;
    display: block;
}

@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    .docs-main {
        padding: 2rem 1rem;
        gap: 1.5rem;
    }
    
    .docs-sidebar {
        display: none;
    }

    .docs-content {
        max-width: 100%;
        overflow-wrap: break-word;
        word-wrap: break-word;
    }

    .docs-content p, .docs-content li, .docs-content a {
        word-break: break-word;
    }

    .docs-title {
        font-size: 1.8rem;
        margin-bottom: 1.5rem;
    }

    .docs-content h2 {
        font-size: 1.3rem;
        margin-top: 2rem;
    }

    .docs-code-block {
        flex-direction: column;
        align-items: flex-start;
        padding: 1rem;
        max-width: 100%;
    }
    .docs-code-block .copy-btn {
        align-self: flex-end;
    }
    .docs-code-block code {
        width: 100%;
        max-width: 100%;
        padding-bottom: 0.5rem;
        margin-bottom: 0.5rem;
        border-bottom: 1px solid var(--border-color);
        box-sizing: border-box;
        word-break: break-all;
        white-space: pre-wrap;
    }
}