:root {
    --bg-dark: #0a0b14;
    --bg-card: #151725;
    --bg-sidebar: rgba(15, 17, 26, 0.85);

    --primary: #6c5ce7;
    --primary-glow: rgba(108, 92, 231, 0.4);
    --secondary: #00cec9;
    --accent: #fd79a8;

    --text-main: #ffffff;
    --text-muted: #a4b0be;

    --border-color: rgba(255, 255, 255, 0.06);
    --glass-border: rgba(255, 255, 255, 0.08);

    --font-main: 'Outfit', sans-serif;
    --font-code: 'Fira Code', monospace;

    --sidebar-width: 280px;
    --header-height-mobile: 70px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Background Effects */
.background-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.4;
    animation: float 20s infinite alternate ease-in-out;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: var(--primary);
    top: -100px;
    left: -100px;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: var(--secondary);
    bottom: -150px;
    right: -100px;
    animation-delay: -5s;
}

.grid-overlay {
    position: absolute;
    width: 200%;
    height: 200%;
    background-image:
        linear-gradient(var(--border-color) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-color) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(500px) rotateX(60deg) translateY(-100px) translateZ(-200px);
    opacity: 0.15;
    animation: grid-move 50s linear infinite;
}

@keyframes float {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(100px, 50px);
    }
}

@keyframes grid-move {
    0% {
        transform: perspective(500px) rotateX(60deg) translateY(0) translateZ(-200px);
    }

    100% {
        transform: perspective(500px) rotateX(60deg) translateY(50px) translateZ(-200px);
    }
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background: var(--bg-sidebar);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    z-index: 100;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 2rem;
}

.icon-box {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.logo-area h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-area h2 span {
    color: var(--secondary);
}

.search-box {
    position: relative;
    margin-bottom: 2rem;
}

.search-box input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 10px 10px 10px 35px;
    border-radius: 6px;
    color: var(--text-main);
    font-family: var(--font-main);
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 0 2px var(--primary-glow);
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.nav-links {
    list-style: none;
    flex-grow: 1;
    overflow-y: auto;
    padding-right: 5px;
}

.nav-links::-webkit-scrollbar {
    width: 4px;
}

.nav-links::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 2px;
}

.nav-category {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin: 1.5rem 0 0.5rem 0;
    font-weight: 600;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 6px;
    margin-bottom: 4px;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.nav-links a:hover,
.nav-links a.active {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
}

.nav-links a.active {
    background: linear-gradient(90deg, rgba(108, 92, 231, 0.15), transparent);
    color: var(--primary);
    border-left: 3px solid var(--primary);
}

.nav-links a i {
    width: 20px;
    text-align: center;
}

.api-status {
    margin-top: auto;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    border: 1px solid var(--border-color);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #00b894;
    box-shadow: 0 0 10px #00b894;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(0, 184, 148, 0.7);
    }

    70% {
        opacity: 1;
        box-shadow: 0 0 0 5px rgba(0, 184, 148, 0);
    }

    100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(0, 184, 148, 0);
    }
}

/* Main Content */
.content-wrapper {
    margin-left: var(--sidebar-width);
    padding: 2rem 4rem;
    min-height: 100vh;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
}

.breadcrumbs {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.top-actions {
    display: flex;
    gap: 15px;
}

.btn-primary,
.btn-secondary {
    padding: 8px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-secondary {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 92, 231, 0.4);
}

/* Typography & Sections */
h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-header p {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 3rem;
}

h2 {
    font-size: 2rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 10px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}

h3 {
    margin: 1.5rem 0 1rem 0;
    font-size: 1.3rem;
    color: var(--text-main);
}

p,
li {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 2rem;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.card-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--secondary);
    margin-bottom: 1.5rem;
}

/* Code Viewer */
.code-viewer,
.tab-code-viewer {
    background: #0e1017;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    margin: 1.5rem 0;
    position: relative;
    overflow: hidden;
}

.code-header {
    background: rgba(255, 255, 255, 0.03);
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.dots {
    display: flex;
    gap: 6px;
}

.dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #3b3f4e;
}

.dots span:nth-child(1) {
    background: #ff5f56;
}

.dots span:nth-child(2) {
    background: #ffbd2e;
}

.dots span:nth-child(3) {
    background: #27c93f;
}

.lang-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: var(--font-code);
}

pre {
    padding: 1.5rem;
    padding-right: 4rem;
    /* Space for copy btn */
    overflow-x: auto;
}

code {
    font-family: var(--font-code);
    color: #e0e6ed;
    font-size: 0.9rem;
}

.copy-btn {
    position: absolute;
    top: 50px;
    /* Below header */
    right: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--text-muted);
    width: 30px;
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s;
}

.copy-btn:hover {
    background: var(--primary);
    color: white;
}

/* Tabs */
.tabs {
    display: flex;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid var(--border-color);
}

.tab {
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 12px 20px;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 0.9rem;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.tab:hover {
    color: var(--text-main);
}

.tab.active {
    color: var(--secondary);
    border-bottom-color: var(--secondary);
    background: rgba(255, 255, 255, 0.02);
}

.code-content {
    display: none;
}

.code-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Endpoints */
.endpoint-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 0.5rem;
    font-family: var(--font-code);
    background: rgba(255, 255, 255, 0.03);
    padding: 10px;
    border-radius: 8px;
    width: fit-content;
    border: 1px solid var(--border-color);
}

.method {
    font-weight: 700;
    font-size: 0.8rem;
    padding: 4px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}

.method.get {
    background: rgba(39, 201, 63, 0.2);
    color: #27c93f;
}

.method.post {
    background: rgba(255, 189, 46, 0.2);
    color: #ffbd2e;
}

.method.delete {
    background: rgba(255, 95, 86, 0.2);
    color: #ff5f56;
}

.method.put {
    background: rgba(0, 206, 201, 0.2);
    color: #00cec9;
}

.url {
    color: var(--text-main);
    font-size: 0.95rem;
}

.table-container {
    overflow-x: auto;
    margin: 1.5rem 0;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card);
}

th,
td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
}

td {
    color: var(--text-muted);
    font-size: 0.9rem;
}

td code {
    background: rgba(255, 255, 255, 0.1);
    padding: 3px 6px;
    border-radius: 4px;
    color: var(--secondary);
}

.info-box {
    background: rgba(108, 92, 231, 0.1);
    border-left: 4px solid var(--primary);
    padding: 1rem;
    border-radius: 0 6px 6px 0;
    display: flex;
    gap: 15px;
    align-items: flex-start;
    margin: 1.5rem 0;
}

.info-box i {
    color: var(--primary);
    margin-top: 4px;
}

.info-box p {
    margin-bottom: 0;
    color: #cbd5e1;
}

/* Footer */
.doc-footer {
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
    padding-top: 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
}

.socials a {
    color: var(--text-muted);
    margin-left: 20px;
    font-size: 1.2rem;
    transition: color 0.2s;
}

.socials a:hover {
    color: var(--primary);
}

/* Mobile Header & Overlay */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height-mobile);
    background: rgba(10, 11, 20, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    z-index: 200;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.logo-area-mobile {
    display: flex;
    align-items: center;
    gap: 12px;
}

.icon-box-mobile {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
}

.logo-area-mobile h2 {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
    padding: 0;
}

.logo-area-mobile h2 span {
    color: var(--secondary);
}

.menu-btn {
    background: transparent;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 99;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Responsive */
@media (max-width: 900px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 300;
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .mobile-header {
        display: flex;
    }

    .content-wrapper {
        margin-left: 0;
        padding: 2rem;
        padding-top: calc(var(--header-height-mobile) + 2rem);
    }

    .top-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        margin-bottom: 2rem;
    }

    .top-actions {
        width: 100%;
    }

    .btn-primary,
    .btn-secondary {
        flex: 1;
        text-align: center;
    }

    h1 {
        font-size: 2.2rem;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }
}