/* ============================================================
   AzuraCast WHMCS Module — Documentation Styles
   Based on c4n Design System (Inter, JetBrains Mono, Green/Cyan/Purple)
   ============================================================ */

/* --- CSS Custom Properties (Light Mode Default) --- */
:root {
    /* Brand Colors */
    --docs-primary: #00c853;
    --docs-primary-rgb: 0, 200, 83;
    --docs-secondary: #00b0ff;
    --docs-secondary-rgb: 0, 176, 255;
    --docs-accent: #7c4dff;
    --docs-accent-rgb: 124, 77, 255;

    /* Semantic Colors */
    --docs-success: #10b981;
    --docs-info: #3b82f6;
    --docs-warning: #f59e0b;
    --docs-danger: #ef4444;

    /* Backgrounds */
    --docs-bg: #f8f9fa;
    --docs-bg-alt: #f0f1f3;
    --docs-surface: rgba(255, 255, 255, 0.95);
    --docs-surface-2: #e5e7eb;

    /* Text */
    --docs-text: #1f2937;
    --docs-text-secondary: #4b5563;
    --docs-text-muted: #6b7280;

    /* Borders */
    --docs-border: #e5e7eb;
    --docs-border-light: #f3f4f6;

    /* Shadows */
    --docs-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
    --docs-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 10px 20px rgba(0, 0, 0, 0.05);
    --docs-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.12);

    /* Layout */
    --docs-sidebar-w: 280px;
    --docs-header-h: 64px;
    --docs-radius: 10px;
    --docs-radius-sm: 6px;
    --docs-radius-lg: 16px;

    /* Code */
    --docs-code-bg: #f3f4f6;
    --docs-code-text: #e11d48;

    /* Transitions */
    --docs-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* Scrollbar */
    --docs-scrollbar-track: #f1f1f1;
    --docs-scrollbar-thumb: #c1c1c1;
}

/* --- Dark Mode --- */
[data-theme="dark"] {
    --docs-bg: #0d1117;
    --docs-bg-alt: #090c10;
    --docs-surface: rgba(22, 27, 34, 0.95);
    --docs-surface-2: #1c2333;
    --docs-text: #e6edf3;
    --docs-text-secondary: #b1bac4;
    --docs-text-muted: #8b949e;
    --docs-border: rgba(48, 54, 61, 0.6);
    --docs-border-light: #21262d;
    --docs-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.2);
    --docs-shadow: 0 4px 6px rgba(0, 0, 0, 0.3), 0 10px 20px rgba(0, 0, 0, 0.2);
    --docs-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.4);
    --docs-code-bg: #1c2129;
    --docs-code-text: #ff7eb3;
    --docs-scrollbar-track: #161b22;
    --docs-scrollbar-thumb: #30363d;
}

/* --- Reset & Base --- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--docs-header-h) + 1.5rem);
    font-size: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--docs-bg);
    color: var(--docs-text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--docs-transition), color var(--docs-transition);
}

::selection {
    background: rgba(var(--docs-primary-rgb), 0.3);
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--docs-scrollbar-track); }
::-webkit-scrollbar-thumb { background: var(--docs-scrollbar-thumb); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--docs-text-muted); }

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
    color: var(--docs-text);
}

h1 { font-size: 2.25rem; margin-bottom: 1rem; }
h2 { font-size: 1.75rem; margin-top: 3rem; margin-bottom: 1rem; padding-bottom: 0.5rem; border-bottom: 1px solid var(--docs-border); }
h3 { font-size: 1.375rem; margin-top: 2rem; margin-bottom: 0.75rem; }
h4 { font-size: 1.125rem; margin-top: 1.5rem; margin-bottom: 0.5rem; }

p { margin-bottom: 1rem; color: var(--docs-text-secondary); }

a {
    color: var(--docs-primary);
    text-decoration: none;
    transition: color var(--docs-transition);
}
a:hover { color: var(--docs-secondary); text-decoration: underline; }

ul, ol { margin-bottom: 1rem; padding-left: 1.5rem; color: var(--docs-text-secondary); }
li { margin-bottom: 0.35rem; }

strong { color: var(--docs-text); font-weight: 600; }

/* Inline code */
code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    background: var(--docs-code-bg);
    color: var(--docs-code-text);
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.875em;
}

/* Code blocks */
pre {
    background: #1c2129;
    color: #e6edf3;
    padding: 1.25rem;
    border-radius: var(--docs-radius);
    overflow-x: auto;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(48, 54, 61, 0.6);
    position: relative;
}
pre code {
    background: none;
    color: inherit;
    padding: 0;
    font-size: 0.85rem;
    line-height: 1.6;
}

/* Syntax highlighting */
.hljs-keyword { color: #ff7b72; }
.hljs-function { color: #d2a8ff; }
.hljs-string { color: #a5d6ff; }
.hljs-variable { color: #ffa657; }
.hljs-comment { color: #6e7681; font-style: italic; }
.hljs-number { color: #79c0ff; }
.hljs-tag { color: #7ee787; }
.hljs-attr { color: #79c0ff; }

/* --- Header / Top Bar --- */
.docs-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--docs-header-h);
    background: var(--docs-surface);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--docs-border);
    z-index: 100;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    transition: background-color var(--docs-transition), border-color var(--docs-transition);
}

.docs-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 100%;
}

.docs-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--docs-text);
}
.docs-logo:hover { text-decoration: none; color: var(--docs-text); }

.docs-logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--docs-primary), var(--docs-secondary));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-weight: 800;
    font-size: 0.85rem;
}

.docs-logo-text span {
    color: var(--docs-text-muted);
    font-weight: 400;
    font-size: 0.85rem;
    margin-left: 0.5rem;
}

.docs-header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Theme Toggle */
.docs-theme-toggle {
    width: 36px;
    height: 36px;
    border: 1px solid var(--docs-border);
    border-radius: 8px;
    background: var(--docs-surface);
    color: var(--docs-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--docs-transition);
    font-size: 1.1rem;
}
.docs-theme-toggle:hover {
    border-color: var(--docs-primary);
    color: var(--docs-primary);
    box-shadow: 0 0 0 3px rgba(var(--docs-primary-rgb), 0.1);
}

/* Sidebar Toggle (Mobile) */
.docs-sidebar-toggle {
    display: none;
    width: 36px;
    height: 36px;
    border: 1px solid var(--docs-border);
    border-radius: 8px;
    background: var(--docs-surface);
    color: var(--docs-text);
    cursor: pointer;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all var(--docs-transition);
}

/* GitHub Link */
.docs-github-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.85rem;
    border: 1px solid var(--docs-border);
    border-radius: 50px;
    color: var(--docs-text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
    transition: all var(--docs-transition);
    text-decoration: none;
}
.docs-github-link:hover {
    border-color: var(--docs-primary);
    color: var(--docs-primary);
    text-decoration: none;
}
.docs-github-link svg { width: 16px; height: 16px; }

/* --- Sidebar --- */
.docs-sidebar {
    position: fixed;
    top: var(--docs-header-h);
    left: 0;
    bottom: 0;
    width: var(--docs-sidebar-w);
    background: var(--docs-surface);
    border-right: 1px solid var(--docs-border);
    overflow-y: auto;
    padding: 1.25rem 0;
    z-index: 50;
    transition: transform 0.35s ease-in-out, background-color var(--docs-transition), border-color var(--docs-transition);
    scrollbar-width: thin;
    scrollbar-color: var(--docs-scrollbar-thumb) transparent;
}

/* Sidebar Search */
.docs-search {
    padding: 0 1rem 1rem;
}

.docs-search-input {
    width: 100%;
    padding: 0.5rem 1rem 0.5rem 2.25rem;
    border: 1px solid var(--docs-border);
    border-radius: 50px;
    background: var(--docs-bg);
    color: var(--docs-text);
    font-size: 0.8rem;
    font-family: inherit;
    outline: none;
    transition: all var(--docs-transition);
}
.docs-search-input::placeholder { color: var(--docs-text-muted); }
.docs-search-input:focus {
    border-color: var(--docs-primary);
    box-shadow: 0 0 0 3px rgba(var(--docs-primary-rgb), 0.15);
}

.docs-search-wrap {
    position: relative;
}
.docs-search-wrap::before {
    content: '';
    position: absolute;
    left: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    pointer-events: none;
}

/* Sidebar Navigation */
.docs-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.docs-nav-section {
    margin-bottom: 0.25rem;
}

.docs-nav-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 1.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--docs-text);
    text-decoration: none;
    transition: all var(--docs-transition);
    border-left: 3px solid transparent;
}
.docs-nav-title:hover {
    color: var(--docs-primary);
    text-decoration: none;
    background: rgba(var(--docs-primary-rgb), 0.04);
}
.docs-nav-title.active {
    color: var(--docs-primary);
    border-left-color: var(--docs-primary);
    background: rgba(var(--docs-primary-rgb), 0.08);
}

.docs-nav-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    background: rgba(var(--docs-primary-rgb), 0.1);
    color: var(--docs-primary);
    flex-shrink: 0;
    transition: all var(--docs-transition);
}
.docs-nav-title.active .docs-nav-icon {
    background: var(--docs-primary);
    color: #000;
}

.docs-nav-children {
    list-style: none;
    padding: 0;
    margin: 0 0 0.5rem;
}

.docs-nav-child {
    position: relative;
}

.docs-nav-child a {
    display: block;
    padding: 0.35rem 1.25rem 0.35rem 3.75rem;
    font-size: 0.8rem;
    color: var(--docs-text-muted);
    text-decoration: none;
    transition: all var(--docs-transition);
    border-left: 3px solid transparent;
}
.docs-nav-child a::before {
    content: '';
    position: absolute;
    left: 2.65rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--docs-border);
    border-radius: 1px;
}
.docs-nav-child a:hover {
    color: var(--docs-primary);
    background: rgba(var(--docs-primary-rgb), 0.04);
}
.docs-nav-child a.active {
    color: var(--docs-primary);
    font-weight: 500;
}
.docs-nav-child a.active::before {
    background: var(--docs-primary);
}

/* Version badge in sidebar */
.docs-version-badge {
    display: inline-block;
    padding: 0.1rem 0.45rem;
    border-radius: 50px;
    font-size: 0.65rem;
    font-weight: 600;
    background: rgba(var(--docs-primary-rgb), 0.1);
    color: var(--docs-primary);
    margin-left: auto;
}

/* --- Main Content --- */
.docs-content {
    margin-left: var(--docs-sidebar-w);
    padding-top: var(--docs-header-h);
    min-height: 100vh;
    transition: margin-left 0.35s ease-in-out;
}

.docs-content-inner {
    max-width: 920px;
    margin: 0 auto;
    padding: 2.5rem 2rem 6rem;
}

/* --- Article & Section --- */
.docs-article {
    margin-bottom: 1rem;
}

.docs-article + .docs-article {
    padding-top: 2rem;
    border-top: 1px solid var(--docs-border);
}

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

.docs-section-intro {
    font-size: 1.05rem;
    color: var(--docs-text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

/* --- Callout Boxes --- */
.docs-callout {
    padding: 1rem 1.25rem;
    border-radius: var(--docs-radius);
    border-left: 4px solid;
    margin: 1.25rem 0;
    font-size: 0.9rem;
    line-height: 1.6;
}
.docs-callout p { margin-bottom: 0.5rem; color: inherit; }
.docs-callout p:last-child { margin-bottom: 0; }
.docs-callout strong { color: inherit; }

.docs-callout-title {
    font-weight: 600;
    margin-bottom: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.docs-callout-info {
    border-color: var(--docs-info);
    background: rgba(59, 130, 246, 0.06);
    color: #1e40af;
}
[data-theme="dark"] .docs-callout-info { background: rgba(59, 130, 246, 0.1); color: #93bbfd; }

.docs-callout-warning {
    border-color: var(--docs-warning);
    background: rgba(245, 158, 11, 0.06);
    color: #92400e;
}
[data-theme="dark"] .docs-callout-warning { background: rgba(245, 158, 11, 0.1); color: #fbbf24; }

.docs-callout-danger {
    border-color: var(--docs-danger);
    background: rgba(239, 68, 68, 0.06);
    color: #991b1b;
}
[data-theme="dark"] .docs-callout-danger { background: rgba(239, 68, 68, 0.1); color: #fca5a5; }

.docs-callout-success {
    border-color: var(--docs-success);
    background: rgba(16, 185, 129, 0.06);
    color: #065f46;
}
[data-theme="dark"] .docs-callout-success { background: rgba(16, 185, 129, 0.1); color: #6ee7b7; }

.docs-callout-tip {
    border-color: var(--docs-accent);
    background: rgba(124, 77, 255, 0.06);
    color: #4c1d95;
}
[data-theme="dark"] .docs-callout-tip { background: rgba(124, 77, 255, 0.1); color: #c4b5fd; }

/* --- Screenshots / Images --- */
.docs-img-wrap {
    margin: 1.5rem 0;
    border-radius: var(--docs-radius);
    overflow: hidden;
    border: 1px solid var(--docs-border);
    background: var(--docs-surface-2);
    transition: box-shadow var(--docs-transition);
}
.docs-img-wrap:hover {
    box-shadow: var(--docs-shadow-lg);
}

.docs-img-wrap img {
    display: block;
    width: 100%;
    height: auto;
    cursor: zoom-in;
}

.docs-img-caption {
    padding: 0.6rem 1rem;
    font-size: 0.8rem;
    color: var(--docs-text-muted);
    background: var(--docs-bg-alt);
    border-top: 1px solid var(--docs-border);
    text-align: center;
}

/* --- Steps / Numbered List --- */
.docs-steps {
    counter-reset: step;
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.docs-step {
    counter-increment: step;
    position: relative;
    padding: 0 0 1.5rem 3.25rem;
    border-left: 2px solid var(--docs-border);
    margin-left: 0.85rem;
}
.docs-step:last-child { border-left-color: transparent; padding-bottom: 0; }

.docs-step::before {
    content: counter(step);
    position: absolute;
    left: -0.85rem;
    top: 0;
    width: 1.7rem;
    height: 1.7rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--docs-primary), var(--docs-secondary));
    color: #000;
    font-weight: 700;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.docs-step-title {
    font-weight: 600;
    font-size: 1rem;
    color: var(--docs-text);
    margin-bottom: 0.5rem;
}

/* --- Table --- */
.docs-table-wrap {
    overflow-x: auto;
    margin: 1.25rem 0;
    border-radius: var(--docs-radius);
    border: 1px solid var(--docs-border);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

th {
    background: var(--docs-bg-alt);
    font-weight: 600;
    text-align: left;
    padding: 0.75rem 1rem;
    color: var(--docs-text);
    border-bottom: 2px solid var(--docs-border);
    white-space: nowrap;
}

td {
    padding: 0.65rem 1rem;
    border-bottom: 1px solid var(--docs-border);
    color: var(--docs-text-secondary);
}

tr:last-child td { border-bottom: none; }
tr:nth-child(even) { background: rgba(var(--docs-primary-rgb), 0.02); }
[data-theme="dark"] tr:nth-child(even) { background: rgba(19, 25, 32, 0.4); }

/* --- Badges --- */
.docs-badge {
    display: inline-block;
    padding: 0.15rem 0.55rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.docs-badge-green { background: rgba(var(--docs-primary-rgb), 0.15); color: var(--docs-primary); }
.docs-badge-blue { background: rgba(var(--docs-secondary-rgb), 0.15); color: var(--docs-secondary); }
.docs-badge-purple { background: rgba(var(--docs-accent-rgb), 0.15); color: var(--docs-accent); }
.docs-badge-red { background: rgba(239, 68, 68, 0.15); color: #ef4444; }
.docs-badge-amber { background: rgba(245, 158, 11, 0.15); color: #d97706; }

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

.docs-feature-card {
    padding: 1.25rem;
    border-radius: var(--docs-radius);
    border: 1px solid var(--docs-border);
    background: var(--docs-surface);
    transition: all var(--docs-transition);
}
.docs-feature-card:hover {
    border-color: rgba(var(--docs-primary-rgb), 0.3);
    box-shadow: var(--docs-shadow);
    transform: translateY(-2px);
}

.docs-feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    background: linear-gradient(135deg, rgba(var(--docs-primary-rgb), 0.15), rgba(var(--docs-secondary-rgb), 0.15));
    color: var(--docs-primary);
}

.docs-feature-card h4 {
    margin-top: 0;
    margin-bottom: 0.35rem;
    font-size: 0.95rem;
}

.docs-feature-card p {
    font-size: 0.85rem;
    margin-bottom: 0;
    color: var(--docs-text-muted);
}

/* --- Requirements Table --- */
.docs-req-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.docs-req-item {
    padding: 1rem;
    border-radius: var(--docs-radius-sm);
    border: 1px solid var(--docs-border);
    background: var(--docs-surface);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.docs-req-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.docs-req-label {
    font-size: 0.8rem;
    color: var(--docs-text-muted);
}

.docs-req-value {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--docs-text);
}

/* --- Copy Button (Code Blocks) --- */
.docs-code-wrap {
    position: relative;
}

.docs-copy-btn {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.3rem 0.6rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    color: #8b949e;
    font-size: 0.7rem;
    cursor: pointer;
    transition: all var(--docs-transition);
    font-family: inherit;
}
.docs-copy-btn:hover { background: rgba(255, 255, 255, 0.2); color: #e6edf3; }
.docs-copy-btn.copied { background: rgba(var(--docs-primary-rgb), 0.3); color: var(--docs-primary); }

/* --- Back to Top --- */
.docs-back-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--docs-primary);
    color: #000;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: var(--docs-shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--docs-transition);
    z-index: 90;
}
.docs-back-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.docs-back-top:hover {
    transform: translateY(-3px);
    box-shadow: var(--docs-shadow-lg), 0 0 20px rgba(var(--docs-primary-rgb), 0.3);
}

/* --- Lightbox Overlay --- */
.docs-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.docs-lightbox.active {
    opacity: 1;
    visibility: visible;
}
.docs-lightbox img {
    max-width: 95vw;
    max-height: 92vh;
    border-radius: var(--docs-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.docs-lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--docs-transition);
}
.docs-lightbox-close:hover { background: rgba(255, 255, 255, 0.2); }

/* --- Footer --- */
.docs-footer {
    border-top: 1px solid var(--docs-border);
    padding: 2rem;
    text-align: center;
    color: var(--docs-text-muted);
    font-size: 0.8rem;
    margin-top: 3rem;
}

.docs-footer a { color: var(--docs-primary); }

/* --- Responsive --- */
@media (max-width: 1199px) {
    .docs-sidebar {
        transform: translateX(-100%);
    }
    .docs-sidebar.open {
        transform: translateX(0);
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
    }
    .docs-content {
        margin-left: 0;
    }
    .docs-sidebar-toggle {
        display: flex;
    }
    .docs-sidebar-overlay {
        position: fixed;
        inset: 0;
        top: var(--docs-header-h);
        background: rgba(0, 0, 0, 0.4);
        z-index: 40;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    .docs-sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }
}

@media (max-width: 768px) {
    html { font-size: 15px; }
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.2rem; }
    .docs-content-inner { padding: 1.5rem 1rem 4rem; }
    .docs-feature-grid { grid-template-columns: 1fr; }
    .docs-req-grid { grid-template-columns: 1fr; }
    .docs-github-link span { display: none; }
    pre { font-size: 0.8rem; padding: 1rem; }
}

@media (max-width: 480px) {
    .docs-content-inner { padding: 1.25rem 0.75rem 3rem; }
    .docs-header { padding: 0 0.75rem; }
}

/* --- Print --- */
@media print {
    .docs-sidebar,
    .docs-header,
    .docs-back-top,
    .docs-theme-toggle,
    .docs-sidebar-toggle { display: none !important; }
    .docs-content { margin-left: 0 !important; padding-top: 0 !important; }
    body { background: #fff; color: #000; }
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
}
