:root {
    --primary: #d96126;
    --primary-dark: #b84d19;
    --primary-light: #ff8c52;
    --accent: #6366f1;
    --bg-body: #0a0a0c;
    --bg-card: #16161a;
    --bg-sidebar: #0f0f12;
    --text-main: #f8fafc;
    --text-secondary: #94a3b8;
    --border: #2d2d35;
    --code-bg: #1e1e24;
    --method-get: #34d399;
    --method-post: #60a5fa;
    --method-put: #fbbf24;
    --method-delete: #f87171;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    display: flex;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-body);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 200;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Sidebar */
.sidebar {
    width: 300px;
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--border);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    padding: 2rem 0;
    z-index: 100;
    transition: transform 0.3s ease;
}

.brand {
    padding: 0 2rem 2rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.logo-img {
    width: 40px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(217, 97, 38, 0.3);
}

.brand-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.brand-text span {
    color: var(--primary);
}

.api-version {
    font-size: 0.7rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 0.5rem;
    color: var(--primary);
    font-weight: 600;
}

.nav-section {
    padding: 1.5rem 2rem 0.5rem;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    font-weight: 700;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 0.8rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.95rem;
    border-left: 3px solid transparent;
    font-weight: 500;
}

.nav-item:hover {
    background: var(--glass);
    color: var(--text-main);
}

.nav-item.active {
    background: rgba(217, 97, 38, 0.1);
    color: var(--primary);
    border-left: 3px solid var(--primary);
}

/* Main Content - FIXED DESKTOP */
.content {
    margin-left: 300px;
    flex-grow: 1;
    padding: 3rem 5rem;
    max-width: calc(100vw - 300px);
    width: 100%;
    box-sizing: border-box;
}

header {
    margin-bottom: 4rem;
    position: relative;
}

.hero-gradient {
    position: absolute;
    top: -100px;
    right: -100px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(217, 97, 38, 0.1) 0%, transparent 70%);
    z-index: -1;
}

h1 {
    font-size: 3.5rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.2rem;
    font-weight: 700;
    margin: 4rem 0 1.5rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

h2::before {
    content: '';
    width: 4px;
    height: 1.5rem;
    background: var(--primary);
    border-radius: 2px;
}

h3 {
    font-size: 1.4rem;
    margin: 2rem 0 1rem;
    font-weight: 600;
    color: var(--primary-light);
}

p {
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.base-url {
    display: inline-flex;
    align-items: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    color: var(--primary-light);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    flex-wrap: wrap;
    gap: 0.5rem;
}

.base-url .label {
    color: var(--text-secondary);
    margin-right: 0.5rem;
}

/* Endpoint Card */
.endpoint {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    margin-bottom: 3rem;
    overflow: hidden;
    transition: border-color 0.3s ease, transform 0.3s ease;
    max-width: 100%;
}

.endpoint:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.endpoint-header {
    padding: 1.25rem 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.method {
    font-weight: 800;
    font-size: 0.75rem;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    min-width: 80px;
    text-align: center;
    flex-shrink: 0;
}

.get {
    background-color: var(--method-get);
    box-shadow: 0 0 15px rgba(52, 211, 153, 0.2);
}

.post {
    background-color: var(--method-post);
    box-shadow: 0 0 15px rgba(96, 165, 250, 0.2);
}

.put {
    background-color: var(--method-put);
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.2);
}

.delete {
    background-color: var(--method-delete);
    box-shadow: 0 0 15px rgba(248, 113, 113, 0.2);
}

.path {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 500;
    color: var(--text-main);
    font-size: 1.1rem;
    word-break: break-all;
}

.endpoint-body {
    padding: 2rem;
}

.param-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 1.5rem 0;
    background: var(--glass);
    border-radius: 12px;
    overflow: hidden;
}

.param-table th {
    text-align: left;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    padding: 1rem;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.param-table td {
    padding: 1rem;
    border-top: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.required {
    color: var(--method-delete);
    font-size: 0.7rem;
    font-weight: 700;
    background: rgba(248, 113, 113, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 0.5rem;
}

/* Code Block with Copy Button */
.code-block {
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
    margin: 1rem 0;
}

.code-block::before {
    content: 'JSON';
    position: absolute;
    top: 0;
    right: 50px;
    background: var(--border);
    color: var(--text-secondary);
    font-size: 0.65rem;
    padding: 4px 10px;
    border-bottom-left-radius: 8px;
    font-weight: 700;
}

.copy-btn {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 6px 12px;
    font-size: 0.7rem;
    font-weight: 600;
    cursor: pointer;
    border-bottom-left-radius: 8px;
    transition: background 0.2s ease;
}

.copy-btn:hover {
    background: var(--primary-dark);
}

.copy-btn.copied {
    background: var(--method-get);
}

pre {
    color: #d1d5db;
    font-size: 0.9rem;
    font-family: 'JetBrains Mono', monospace;
    line-height: 1.6;
    overflow-x: auto;
}

.badge-auth {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 999px;
    background-color: rgba(99, 102, 241, 0.1);
    color: var(--accent);
    border: 1px solid rgba(99, 102, 241, 0.2);
    margin-left: auto;
    flex-shrink: 0;
}

.badge-auth::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
}

/* Tabs/Grid for Features */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 2rem;
    border-radius: 20px;
    text-align: left;
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: var(--primary);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background: rgba(217, 97, 38, 0.1);
    color: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Footer styles */
footer {
    margin-top: 5rem;
    padding: 2rem 0;
    border-top: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .content {
        padding: 2rem 3rem;
    }

    h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 1024px) {
    .mobile-menu-toggle {
        display: block;
    }

    .sidebar {
        transform: translateX(-100%);
        width: 280px;
    }

    .sidebar.open {
        transform: translateX(0);
        box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
    }

    .content {
        margin-left: 0;
        padding: 4rem 1.5rem 2rem;
        max-width: 100vw;
        width: 100%;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.6rem;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .endpoint-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .badge-auth {
        margin-left: 0;
    }

    .base-url {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }

    .content {
        padding: 4rem 1.25rem 1rem;
    }

    .endpoint-body {
        padding: 1rem;
    }

    .code-block {
        padding: 1rem;
        font-size: 0.8rem;
    }

    .param-table {
        display: block;
        overflow-x: auto;
    }

    .param-table th,
    .param-table td {
        padding: 0.75rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.75rem;
    }

    .feature-card {
        padding: 1.5rem;
    }

    .feature-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .content {
        padding: 4rem 1rem 1rem;
    }
}