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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #1e1e1e;
    color: #d4d4d4;
    line-height: 1.6;
}

.docs-container {
    max-width: 1400px;
    margin: 0 auto;
}

.docs-header {
    background: #252526;
    padding: 2rem;
    border-bottom: 2px solid #e74c3c;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.docs-header h1 {
    color: #e74c3c;
    font-size: 2rem;
}

.back-btn {
    background: #555;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.2s;
}

.back-btn:hover {
    background: #666;
}

.docs-nav {
    background: #2d2d30;
    padding: 1rem 2rem;
    display: flex;
    gap: 2rem;
    border-bottom: 1px solid #3e3e42;
    position: sticky;
    top: 80px;
    z-index: 99;
    overflow-x: auto;
}

.docs-nav a {
    color: #9cdcfe;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background 0.2s;
    white-space: nowrap;
}

.docs-nav a:hover {
    background: #3e3e42;
}

.docs-content {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.doc-section {
    margin-bottom: 4rem;
    background: #252526;
    padding: 2rem;
    border-radius: 8px;
    border-left: 4px solid #e74c3c;
}

.doc-section h2 {
    color: #e74c3c;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

.doc-section h3 {
    color: #569cd6;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.section-desc {
    color: #888;
    margin-bottom: 2rem;
    font-style: italic;
}

.keyword-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 0.75rem;
    margin-bottom: 2rem;
}

.keyword-item {
    background: #2d2d30;
    padding: 1rem;
    border-radius: 6px;
    border-left: 3px solid #4ec9b0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.keyword-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.keyword-item .tr {
    font-size: 1.2rem;
    font-weight: 600;
    color: #4ec9b0;
    font-family: 'Monaco', 'Menlo', monospace;
}

.keyword-item .en {
    font-size: 1rem;
    color: #ce9178;
    font-family: 'Monaco', 'Menlo', monospace;
    font-style: italic;
}

.keyword-item .desc {
    font-size: 0.9rem;
    color: #aaa;
}

.example {
    background: #1e1e1e;
    padding: 1.5rem;
    border-radius: 6px;
    border: 1px solid #3e3e42;
    margin-top: 2rem;
}

.example h4 {
    color: #dcdcaa;
    margin-bottom: 1rem;
}

.example pre {
    overflow-x: auto;
}

.example code {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', monospace;
    font-size: 0.95rem;
    line-height: 1.8;
    color: #d4d4d4;
}

.quick-ref {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.ref-col h4 {
    color: #dcdcaa;
    margin-bottom: 0.75rem;
    margin-top: 1rem;
}

.ref-col h4:first-child {
    margin-top: 0;
}

.ref-col code {
    display: block;
    background: #2d2d30;
    padding: 0.5rem 1rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
    font-family: 'Monaco', 'Menlo', monospace;
    color: #4ec9b0;
}

.docs-footer {
    text-align: center;
    padding: 3rem 2rem;
    color: #888;
    border-top: 1px solid #3e3e42;
    margin-top: 4rem;
}

.docs-footer p {
    margin-bottom: 0.5rem;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #1e1e1e;
}

::-webkit-scrollbar-thumb {
    background: #424242;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #4e4e4e;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .docs-header {
        flex-direction: column;
        gap: 1rem;
        padding: 1.5rem;
    }

    .docs-nav {
        padding: 0.75rem 1rem;
        gap: 1rem;
    }

    .docs-content {
        padding: 1rem;
    }

    .doc-section {
        padding: 1.5rem;
    }

    .keyword-group {
        grid-template-columns: 1fr;
    }
}
