/* Documentation Styles */

.docs-main {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

.docs-hero {
    text-align: center;
    padding: 4rem 2rem 3rem;
    background: linear-gradient(135deg, rgba(93, 95, 239, 0.05), rgba(124, 58, 237, 0.05));
    border-bottom: 1px solid rgba(93, 95, 239, 0.1);
}

.docs-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #5d5fef, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.docs-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

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

/* Version Selector */
.version-selector {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 3rem;
}

.version-selector label {
    font-weight: 600;
    color: var(--text);
}

#version-select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--background);
    color: var(--text);
    font-size: 1rem;
    cursor: pointer;
}

/* Documentation Sections */
.docs-section {
    margin-bottom: 4rem;
}

.docs-section h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text);
}

/* Documentation Cards */
.docs-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.doc-card {
    display: flex;
    flex-direction: column;
    padding: 2rem;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text);
    transition: all 0.3s ease;
    position: relative;
}

.doc-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(93, 95, 239, 0.15);
    border-color: var(--primary);
}

.doc-card-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(93, 95, 239, 0.1), rgba(124, 58, 237, 0.1));
}

.doc-card-icon svg {
    color: var(--primary);
}

.doc-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.doc-card p {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.doc-version {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(93, 95, 239, 0.1);
    color: var(--primary);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.doc-card-coming-soon {
    opacity: 0.7;
    pointer-events: none;
}

.doc-badge-coming-soon {
    background: rgba(255, 193, 7, 0.1);
    color: #f59e0b;
}

/* Quick Start Grid */
.quick-start-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.quick-start-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text);
    transition: all 0.2s ease;
}

.quick-start-item:hover {
    border-color: var(--primary);
    background: rgba(93, 95, 239, 0.05);
    transform: translateX(4px);
}

.quick-start-item svg {
    flex-shrink: 0;
    color: var(--primary);
}

.quick-start-item span {
    font-weight: 500;
}

/* Integration Cards */
.integration-cards .doc-card {
    min-height: 240px;
}

/* Resource List */
.resource-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.resource-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text);
    transition: all 0.2s ease;
}

.resource-item:hover {
    border-color: var(--primary);
    background: rgba(93, 95, 239, 0.05);
}

.resource-item svg {
    flex-shrink: 0;
    color: var(--primary);
}

.resource-item span {
    font-weight: 500;
}

/* Documentation Tab Navigation */
.docs-tabs {
    background: var(--background);
    border-bottom: 2px solid var(--border);
    margin-bottom: 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.docs-tabs-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
}

.docs-tabs-container::-webkit-scrollbar {
    height: 3px;
}

.docs-tab {
    padding: 1rem 1.5rem;
    color: var(--text-light);
    text-decoration: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    white-space: nowrap;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
}

.docs-tab:hover {
    color: var(--text);
    border-bottom-color: rgba(93, 95, 239, 0.3);
}

.docs-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    font-weight: 600;
}

/* Documentation Content Page Styles */
.docs-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    align-items: start;
}

.docs-sidebar {
    position: sticky;
    top: 7rem;
    height: fit-content;
    max-height: calc(100vh - 9rem);
    width: 100%;
    display: flex;
    flex-direction: column;
}

.docs-sidebar nav {
    background: transparent;
    border: none;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.docs-sidebar h3 {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--text-light);
    margin: 0;
    padding: 0.75rem 0;
    border: none;
    background: var(--background, #ffffff);
    flex-shrink: 0;
    position: relative;
    z-index: 10;
}

.docs-sidebar-scroll {
    overflow-y: auto;
    flex: 1;
    padding-bottom: 1rem;
}

.docs-sidebar-scroll::-webkit-scrollbar {
    width: 6px;
}

.docs-sidebar-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.docs-sidebar-scroll::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

.docs-sidebar-scroll::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.docs-sidebar-section {
    margin-bottom: 2.5rem;
}

.docs-sidebar-section:last-child {
    margin-bottom: 0;
}

.docs-sidebar span {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    line-height: 1.5;
}

.docs-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0 0 2.5rem 0;
}

.docs-sidebar ul:last-child {
    margin-bottom: 0;
}

.docs-sidebar li {
    margin-bottom: 0.4rem;
}

.docs-sidebar a {
    display: block;
    padding: 0.6rem 0.75rem;
    color: var(--text);
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    line-height: 1.5;
    border-left: 3px solid transparent;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

.docs-sidebar a:hover {
    background: rgba(93, 95, 239, 0.05);
    color: var(--primary);
    border-left-color: rgba(93, 95, 239, 0.3);
}

.docs-sidebar a.active {
    background: rgba(93, 95, 239, 0.08);
    color: var(--primary);
    font-weight: 600;
    border-left-color: var(--primary);
}

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

.docs-content h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--text);
}

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

.docs-content h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--text);
}

.docs-content p {
    line-height: 1.8;
    color: var(--text);
    margin-bottom: 1.5rem;
}

.docs-content ul,
.docs-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.docs-content li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

.docs-content code {
    background: rgba(93, 95, 239, 0.1);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.9em;
}

.docs-content pre {
    background: var(--background-dark);
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.docs-content pre code {
    background: none;
    padding: 0;
}

.docs-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2rem 0;
    border: 1px solid var(--border);
}

/* Image Placeholder */
.image-placeholder {
    background: linear-gradient(135deg, rgba(93, 95, 239, 0.05), rgba(124, 58, 237, 0.05));
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 3rem;
    text-align: center;
    margin: 2rem 0;
}

.image-placeholder svg {
    color: var(--primary);
    margin-bottom: 1rem;
}

.image-placeholder p {
    color: var(--text-light);
    margin: 0;
}

/* Callout Boxes */
.callout {
    padding: 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
    border-left: 4px solid;
}

.callout-info {
    background: rgba(93, 95, 239, 0.1);
    border-color: var(--primary);
}

.callout-warning {
    background: rgba(255, 193, 7, 0.1);
    border-color: #f59e0b;
}

.callout-success {
    background: rgba(72, 187, 120, 0.1);
    border-color: #48bb78;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .docs-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .docs-sidebar {
        position: static;
        max-height: none;
        margin-bottom: 2rem;
        width: 100%;
    }
    
    .docs-sidebar h3 {
        position: static;
    }
    
    .docs-sidebar nav {
        min-width: auto;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .docs-hero {
        padding: 3rem 1.5rem 2rem;
    }
    
    .docs-hero h1 {
        font-size: 2rem;
    }

    .docs-subtitle {
        font-size: 1rem;
    }
    
    .docs-container {
        padding: 2rem 1rem;
    }

    .docs-cards {
        grid-template-columns: 1fr;
    }

    .quick-start-grid {
        grid-template-columns: 1fr;
    }

    .resource-list {
        grid-template-columns: 1fr;
    }
    
    .docs-layout {
        padding: 1rem;
    }
    
    .docs-sidebar {
        top: 5rem;
    }
    
    .docs-sidebar nav {
        padding: 1rem;
    }
    
    .docs-content {
        padding: 0;
    }
    
    .docs-tabs-container {
        padding: 0 1rem;
        gap: 0.25rem;
    }
    
    .docs-tab {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
}

