/* OddSockets SDK Documentation - Shared Styles */
/* Anthropic-inspired clean, minimal design with muted colors */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    line-height: 1.6;
    color: #374151;
    background-color: #fafafa;
    font-size: 16px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    min-height: 100vh;
}

/* Sidebar Navigation */
.sidebar {
    width: 280px;
    background: #ffffff;
    border-right: 1px solid #e5e7eb;
    padding: 2rem 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar h2 {
    padding: 0 1.5rem;
    margin-bottom: 1.5rem;
    color: #111827;
    font-size: 1.125rem;
    font-weight: 600;
}

.sidebar nav ul {
    list-style: none;
}

.sidebar nav a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: #6b7280;
    text-decoration: none;
    transition: all 0.15s ease;
    border-left: 3px solid transparent;
    font-size: 0.875rem;
}

.sidebar nav a:hover,
.sidebar nav a.active {
    background: #f9fafb;
    color: #374151;
    border-left-color: #9ca3af;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 280px;
    padding: 2rem;
}

/* Header */
.header {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 2.5rem 2rem;
    margin: -2rem -2rem 2rem -2rem;
    text-align: center;
}

.header h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #111827;
    font-weight: 600;
}

.header p {
    font-size: 1rem;
    color: #6b7280;
    max-width: 600px;
    margin: 0 auto;
}

.badges {
    margin: 1.5rem 0 0 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 500;
    border: 1px solid #e5e7eb;
}

/* Content Sections */
.content-section {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.content-section h2 {
    color: #111827;
    font-size: 1.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e5e7eb;
    font-weight: 600;
}

.content-section h3 {
    color: #374151;
    font-size: 1.125rem;
    margin: 1.5rem 0 0.75rem 0;
    font-weight: 600;
}

.content-section p {
    color: #6b7280;
    margin-bottom: 1rem;
}

.content-section ul {
    color: #6b7280;
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.content-section li {
    margin-bottom: 0.25rem;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.feature-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    padding: 1.5rem;
    border-radius: 6px;
}

.feature-card h4 {
    color: #111827;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.feature-card p {
    color: #6b7280;
    font-size: 0.875rem;
    margin: 0;
}

/* Monaco Editor Code Blocks */
.code-block {
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    overflow: hidden;
    margin: 1rem 0;
    position: relative;
    background: #ffffff;
}

.code-block-header {
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    padding: 0.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: #6b7280;
}

.code-block-lang {
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.code-block-copy {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    transition: all 0.15s ease;
}

.code-block-copy:hover {
    background: #e5e7eb;
    color: #374151;
}

.monaco-editor-container {
    height: auto;
    min-height: 100px;
    max-height: 500px;
    overflow: hidden;
}

/* Monaco Editor Overrides for Clean Look */
.monaco-editor {
    background: #ffffff !important;
}

.monaco-editor .margin {
    background: #f9fafb !important;
}

.monaco-editor .monaco-editor-background {
    background: #ffffff !important;
}

/* Fallback for non-Monaco code blocks */
.code-block-fallback {
    background: #1f2937;
    color: #e5e7eb;
    padding: 1.5rem;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    overflow-x: auto;
}

/* Tabs */
.installation-tabs {
    display: flex;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 1rem;
}

.tab-button {
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    border-bottom: 2px solid transparent;
    transition: all 0.15s ease;
    font-size: 0.875rem;
    font-weight: 500;
}

.tab-button.active {
    color: #374151;
    border-bottom-color: #9ca3af;
}

.tab-button:hover {
    color: #374151;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Quick Links */
.quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.quick-link {
    display: block;
    padding: 1.25rem;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    text-decoration: none;
    color: #374151;
    transition: all 0.15s ease;
}

.quick-link:hover {
    background: #f3f4f6;
    border-color: #d1d5db;
}

.quick-link h4 {
    margin-bottom: 0.5rem;
    color: #111827;
    font-size: 0.875rem;
    font-weight: 600;
}

.quick-link p {
    color: #6b7280;
    font-size: 0.875rem;
    margin: 0;
}

/* Performance Stats */
.performance-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.stat-card {
    text-align: center;
    padding: 1.5rem;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
}

.stat-number {
    font-size: 1.875rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #111827;
}

.stat-card div:last-child {
    color: #6b7280;
    font-size: 0.875rem;
}

/* Table of Contents */
.toc {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    padding: 1.5rem;
    border-radius: 6px;
    margin-bottom: 2rem;
}

.toc h3 {
    margin-bottom: 1rem;
    color: #111827;
    font-size: 1rem;
    font-weight: 600;
}

.toc ul {
    list-style: none;
    padding: 0;
}

.toc a {
    color: #6b7280;
    text-decoration: none;
    padding: 0.25rem 0;
    display: block;
    font-size: 0.875rem;
    transition: color 0.15s ease;
}

.toc a:hover {
    color: #374151;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 50;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .container {
        flex-direction: column;
    }

    .header {
        margin: -1rem -1rem 1.5rem -1rem;
        padding: 2rem 1rem;
    }

    .main-content {
        padding: 1rem;
    }

    .feature-grid,
    .quick-links,
    .performance-stats {
        grid-template-columns: 1fr;
    }
}

/* Mobile Menu Button */
.mobile-menu-button {
    display: none;
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 60;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 0.5rem;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .mobile-menu-button {
        display: block;
    }
}

/* Utility Classes */
.text-muted {
    color: #6b7280;
}

.text-small {
    font-size: 0.875rem;
}

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
