:root {
    --primary-color: #000000;
    --primary-dark: #000000;
    --secondary-color: #000000;
    --secondary-hover: #1a1a1a;
    --accent-color: #000000;
    --bg-light: #ffffff;
    --text-dark: #000000;
    --text-muted: #6b7280;
    --sidebar-bg: #000000;
    --sidebar-text: #9ca3af;
    --sidebar-active: #ffffff;
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
    --glass-bg: rgba(255, 255, 255, 0.95);
    --glass-border: rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', 'Helvetica', 'Arial', 'Lucida', sans-serif;
}

body {
    background-color: var(--bg-light);
    color: var(--text-dark);
    display: flex;
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.5;
    font-weight: 300;
}

/* Sidebar Styling */
.sidebar {
    width: 280px;
    background-color: var(--sidebar-bg);
    color: var(--sidebar-text);
    height: 100vh;
    position: sticky;
    top: 0;
    padding: 2.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    z-index: 1000;
    /* Increased for mobile drawer */
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.logo-container {
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 2rem;
}

.logo-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.brand-logo {
    height: 58px;
    width: auto;
    display: block;
}

.logo-container h1 {
    color: white;
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    margin: 0;
}

.logo-container span {
    color: white;
    opacity: 0.7;
}

/* Page Layout */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative;
    background: var(--bg-light);
}

.content-area {
    display: flex;
    flex-direction: row;
    flex: 1;
    position: relative;
}

.top-header {
    height: 70px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    padding: 0 3rem;
    position: sticky;
    top: 0;
    z-index: 900;
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 600px;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 1rem;
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    pointer-events: none;
}

#docs-search {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    background: #f3f4f6;
    border: 1px solid transparent;
    border-radius: 0.75rem;
    font-size: 0.95rem;
    color: var(--text-dark);
    transition: all 0.3s ease;
}

#docs-search:focus {
    outline: none;
    background: white;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.05);
}

.search-results-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    max-height: 480px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.search-results-dropdown.active {
    display: block;
}

.search-result-item {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f3f4f6;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    text-decoration: none;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #f9fafb;
}

.result-title {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1rem;
}

.result-context {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.result-match {
    background: #fffbeb;
    color: #92400e;
    font-weight: 600;
    padding: 0 0.2rem;
    border-radius: 0.2rem;
}

.no-results {
    padding: 2rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Sidebar Integrated Language Selector */
.language-selector {
    width: auto;
}

.custom-dropdown {
    position: relative;
    width: 100%;
    cursor: pointer;
    user-select: none;
}

.dropdown-selected {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.5rem;
    padding: 0.25rem 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: 700;
    font-size: 0.75rem;
    transition: all 0.3s ease;
}

.lang-flag {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.dropdown-selected:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
    color: white;
}

.arrow-icon {
    width: 12px;
    height: 12px;
    color: white;
    transition: transform 0.3s ease;
}

.custom-dropdown.active .arrow-icon {
    transform: rotate(180deg);
}

.dropdown-options {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    width: 140px;
    background: rgba(18, 18, 18, 0.95);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    list-style: none;
    padding: 0.3rem;
    display: none;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    animation: dropdownPop 0.2s ease-out;
}

@keyframes dropdownPop {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.custom-dropdown.active .dropdown-options {
    display: block;
}

.dropdown-options li {
    padding: 0.5rem 0.5rem;
    border-radius: 0.5rem;
    color: var(--sidebar-text);
    transition: all 0.2s ease;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.dropdown-options li .lang-flag {
    width: 20px;
    height: 20px;
    border-radius: 50%;
}

.dropdown-options li:hover {
    background: white;
    color: black;
}

.dropdown-options li.active {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-weight: 700;
}

.nav-links {
    list-style: none;
}

.nav-item {
    margin-bottom: 0.05rem;
}

.nav-category {
    margin: 1.5rem 0 0 0.75rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: #f3f4f6;
    text-transform: none;
    letter-spacing: 0.02em;
    padding-bottom: 0.2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 0.2rem 1rem;
    color: var(--sidebar-text);
    text-decoration: none;
    border-radius: 0.75rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 400;
    font-size: 0.95rem;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: white;
    transform: translateX(4px);
}

.nav-link.active {
    background: var(--sidebar-active);
    color: black;
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.sidebar nav {
    flex-grow: 1;
    overflow-y: auto;
    margin-right: -1rem;
    padding-right: 1rem;
    /* Custom Scrollbar */
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.sidebar nav::-webkit-scrollbar {
    width: 6px;
}

.sidebar nav::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar nav::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.4);
    border-radius: 20px;
    border: 2px solid transparent;
    background-clip: content-box;
}

.sidebar nav::-webkit-scrollbar-thumb:hover {
    background-color: rgba(255, 255, 255, 0.6);
}

.sidebar-footer {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: auto;
}

.social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.2rem;
}

.social-links a {
    color: var(--sidebar-text);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.social-links a:hover {
    color: white;
    transform: translateY(-2px);
}

.social-links svg {
    width: 20px;
    height: 20px;
}

/* Main Content Area */

.main-content {
    flex: 1;
    padding: 2rem 3rem;
    width: 100%;
    min-width: 0;
    /* Prevents flex items from overflowing */
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.content-card {
    background: var(--card-bg);
    padding: 4rem;
    border-radius: 1.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    max-width: 1000px;
    /* Limit text width for readability while allowing container to grow */
    margin: 0 auto;
}

/* Intro Section */
.hero {
    margin-bottom: 4rem;
    text-align: center;
}

.hero-header {
    background: linear-gradient(rgba(0, 0, 0, 0.85), rgba(17, 17, 17, 0.95)), url('../assets/hero-bg.png');
    background-size: cover;
    background-position: center;
    padding: 2rem 2rem;
    border-radius: 1.5rem;
    margin-bottom: 1.5rem;
    color: white;
    box-shadow: 0 15px 30px -10px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-header h2 {
    font-size: 2.2rem;
    font-weight: 900;
    color: white;
    letter-spacing: -0.05em;
    margin-bottom: 0.5rem;
    line-height: 1.1;
}

.hero h2 span {
    color: var(--secondary-color);
}

.hero-header p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.4;
}

.grid-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}

.feature-card {
    background: white;
    padding: 1.5rem;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#home-categories {
    grid-template-columns: repeat(auto-fit, minmax(240px, 420px));
    justify-content: center;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px -10px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
    background: #fdfdfd;
}

.feature-card .icon {
    width: 32px;
    height: 32px;
    color: black;
    margin-bottom: 0.5rem;
    transition: transform 0.3s ease, color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-card .icon svg {
    width: 100%;
    height: 100%;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.feature-card:hover .icon {
    transform: scale(1.1);
}

.feature-card h3 {
    font-size: 1.15rem;
    color: var(--primary-color);
    font-weight: 700;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.4;
}

/* Markdown Content Styling */
#doc-content h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 2rem;
    color: var(--primary-color);
    letter-spacing: -0.03em;
}

#doc-content h2 {
    font-size: 1.9rem;
    font-weight: 700;
    margin-top: 5rem;
    margin-bottom: 1.25rem;
    color: var(--primary-color);
    border-left: none !important;
    padding-left: 0 !important;
}

#doc-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

#doc-content p {
    font-size: 1.02rem;
    margin-bottom: 1.5rem;
    color: #475569;
    line-height: 1.5;
    font-weight: 300;
}

#doc-content ul,
#doc-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.75rem;
    line-height: 1.5;
    font-weight: 300;
}

#doc-content li {
    font-size: 1.02rem;
    margin-bottom: 0.75rem;
    color: #475569;
    font-weight: 300;
}

#doc-content code {
    background: #f1f5f9;
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    font-family: 'Fira Code', monospace;
    font-size: 0.9em;
    color: var(--primary-color);
}

#doc-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 2rem;
    border-radius: 1rem;
    overflow-x: auto;
    margin-bottom: 2rem;
    font-family: 'Fira Code', monospace;
    line-height: 1.5;
}

#doc-content a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 700;
    border-bottom: 2px solid #e5e7eb;
    transition: all 0.2s;
}

#doc-content a:hover {
    border-bottom-color: black;
    color: black;
}

/* Table Styling */
.table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin: 2rem 0;
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    background: white;
    -webkit-overflow-scrolling: touch;
    /* smooth scrolling on iOS */
}

#doc-content table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
}

#doc-content th {
    background-color: #f1f5f9;
    color: var(--primary-color);
    font-weight: 700;
    text-align: left;
    padding: 1rem 1.25rem;
    border-bottom: 2px solid var(--border-color);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

#doc-content th:nth-child(1),
#doc-content th:nth-child(2) {
    min-width: 200px;
}

#doc-content td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.95rem;
    color: #475569;
    vertical-align: top;
}

#doc-content tr:last-child td {
    border-bottom: none;
}

#doc-content tr:nth-child(even) {
    background-color: #f8fafc;
}

#doc-content tr:hover {
    background-color: #f1f5f9;
}

/* Badge styles for types in tables */
#doc-content td:nth-child(3) code {
    background: #e0f2fe;
    color: #0369a1;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
}

/* Page Navigation Hooks */
.page-nav {
    display: none;
    justify-content: space-between;
    margin: 4rem auto 2rem auto;
    padding-top: 2.5rem;
    border-top: 1px solid #e5e7eb;
    width: 100%;
    max-width: 850px;
    /* Match content width */
}

.nav-prev,
.nav-next {
    flex: 1;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-next {
    text-align: right;
    align-items: flex-end;
}

.nav-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.nav-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    font-family: 'Poppins', 'Helvetica', 'Arial', 'Lucida', sans-serif;
    transition: color 0.2s;
}

.nav-prev:hover .nav-title,
.nav-next:hover .nav-title {
    color: #000;
    text-decoration: underline;
}

/* Cleanup old pseudo-elements */
.nav-prev::before,
.nav-next::after {
    display: none !important;
}

@media (max-width: 768px) {
    .page-nav {
        flex-direction: column;
        gap: 2rem;
        padding: 2.5rem 1rem 0 1rem;
    }

    .nav-next {
        text-align: left;
        align-items: flex-start;
    }
}

#doc-content blockquote {
    padding: 1.25rem 1.5rem;
    margin: 2rem 0;
    border-radius: 8px;
    border-left: 4px solid #e5e7eb;
    background: #f9fafb;
    color: #374151;
}

#doc-content blockquote>p:first-child {
    margin-top: 0;
}

#doc-content blockquote>p:last-child {
    margin-bottom: 0;
}

#doc-content img {
    max-width: 100%;
    width: auto;
    height: auto;
    border-radius: 0.5rem;
    display: block;
    margin: 1.5rem auto;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Alert Types */
#doc-content .markdown-alert {
    padding: 1rem 1.25rem;
    margin: 2rem 0;
    border-left: 4px solid #e5e7eb;
    border-radius: 0 8px 8px 0;
}

#doc-content .markdown-alert .markdown-alert-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

#doc-content .markdown-alert-note {
    border-left-color: #3b82f6;
    background: #eff6ff;
}

#doc-content .markdown-alert-note .markdown-alert-title {
    color: #1d4ed8;
}

#doc-content .markdown-alert-important {
    border-left-color: #ef4444;
    background: #fef2f2;
}

#doc-content .markdown-alert-important .markdown-alert-title {
    color: #991b1b;
}

#doc-content .markdown-alert-warning {
    border-left-color: #f59e0b;
    background: #fffbeb;
}

#doc-content .markdown-alert-warning .markdown-alert-title {
    color: #b45309;
}

#doc-content .markdown-alert-tip {
    border-left-color: #10b981;
    background: #ecfdf5;
}

#doc-content .markdown-alert-tip .markdown-alert-title {
    color: #047857;
}



#doc-content img.optimized {
    max-width: 380px;
    margin: 1.5rem auto;
    border: 1px solid var(--border-color);
}

#doc-content img.medium {
    max-width: 600px;
    margin: 1.5rem auto;
    border: 1px solid var(--border-color);
}

#doc-content img.centered {
    max-width: 100%;
    width: auto;
    display: block;
    margin: 2rem auto;
}

#doc-content img.natural {
    width: auto;
    max-width: 100%;
    display: block;
    margin: 2rem auto;
}

.img-row {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
    margin: 2rem 0;
}

.img-row .optimized {
    flex: 1;
    min-width: 280px;
    max-width: 450px !important;
    margin: 0 !important;
}

#doc-content p+p>em,
#doc-content p>em,
#doc-content figcaption {
    display: block;
    text-align: center;
    color: #6b7280;
    font-size: 0.9rem;
    margin-top: -1.5rem;
    margin-bottom: 2.5rem;
    font-style: italic;
}

#doc-content figure {
    margin: 2rem 0;
    text-align: center;
}

#doc-content figure img {
    margin: 0 auto 1.5rem auto !important;
}

#doc-content figure figcaption {
    margin-top: 0;
}

/* ToC Sidebar Styling */
.toc-sidebar {
    width: 25vw;
    max-width: 320px;
    flex-shrink: 0;
    padding: 4rem 2rem;
    position: sticky;
    top: 70px;
    /* Offset for top-header */
    height: calc(100vh - 70px);
    border-left: 1px solid var(--border-color);
    background: transparent;
    overflow-y: auto;
}

.toc-container h4 {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

#toc-links {
    list-style: none;
    padding: 0;
}

.toc-item {
    margin-bottom: 0.75rem;
}

.toc-link {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    line-height: 1.4;
    transition: all 0.2s ease;
    border-left: 2px solid transparent;
    padding-left: 0.85rem;
    margin-left: -2px;
    /* Overlay default border */
}

.toc-link:hover {
    color: var(--primary-color);
}

.toc-link.active {
    color: var(--primary-color);
    font-weight: 600;
    border-left-color: var(--primary-color);
}

.toc-item[data-level="3"] {
    padding-left: 1rem;
}

.toc-item[data-level="3"] .toc-link {
    font-size: 0.8rem;
}

/* Hide ToC on Home page */
body.is-home .toc-sidebar {
    display: none;
}

body.is-home .main-content {
    max-width: 1100px;
    margin: 0 auto;
}

/* Responsive */
#menu-toggle {
    display: none;
    position: fixed;
    top: 1.5rem;
    left: 1.5rem;
    z-index: 1100;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

#menu-toggle:hover {
    transform: scale(1.05);
    background: #f8f9fa;
}

#menu-toggle svg {
    width: 22px;
    height: 22px;
}

#menu-toggle line {
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
    transform-origin: center;
    transform-box: fill-box;
    /* Critical for Firefox SVG transform reliability */
}

#menu-toggle.open .line-mid {
    opacity: 0;
}

#menu-toggle.open .line-top {
    transform: translateY(6px) rotate(45deg);
}

#menu-toggle.open .line-bot {
    transform: translateY(-6px) rotate(-45deg);
}

#sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 950;
    animation: fadeIn 0.2s ease-out;
}

@media (max-width: 1200px) {
    .toc-sidebar {
        display: none;
    }

    .main-content {
        max-width: 1100px;
        margin: 0 auto;
    }
}

@media (max-width: 992px) {
    #menu-toggle {
        display: flex;
    }

    .toc-sidebar {
        display: none;
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        transform: translateX(-100%);
        visibility: hidden;
        box-shadow: 20px 0 50px rgba(0, 0, 0, 0.1);
        width: 280px;
        padding: 5.5rem 1.5rem 3rem 1.5rem;
        /* Increased top padding to clear hamburger */
    }

    .sidebar.open {
        transform: translateX(0);
        visibility: visible;
    }

    .sidebar.open+#sidebar-overlay {
        display: block;
    }

    .main-wrapper {
        padding-top: 0;
        flex-direction: column;
    }

    .top-header {
        padding: 0 1.5rem 0 5rem;
        height: 70px;
    }

    .content-area {
        flex-direction: column;
    }

    .main-content {
        padding: 1.25rem 1rem;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 0.75rem;
    }

    .content-card {
        padding: 2rem 1rem;
        width: 100%;
        border-radius: 1rem;
    }

    .hero-header h2 {
        font-size: 1.6rem;
    }

    .hero-header {
        padding: 1.25rem 0.75rem;
    }

    .main-wrapper {
        padding-top: 5rem;
    }

    /* Better Table Responsiveness on Mobile */
    .table-wrapper {
        position: relative;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        margin: 1.5rem -1rem;
        width: calc(100% + 2rem);
        border-radius: 0;
        border-left: none;
        border-right: none;
        background: white;
    }

    #doc-content th {
        white-space: normal;
        min-width: 80px !important;
        padding: 0.6rem;
        font-size: 0.7rem;
    }

    #doc-content td {
        padding: 0.6rem;
        min-width: 80px;
        font-size: 0.8rem;
    }

    #doc-content th:nth-child(1) {
        min-width: 100px !important;
    }
}

@media (max-width: 480px) {
    .content-card {
        padding: 1.5rem 0.75rem;
    }

    #doc-content th,
    #doc-content td {
        padding: 0.5rem;
        font-size: 0.75rem;
    }
}

/* Button Styling */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    text-decoration: none !important;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 1rem;
    border: none !important;
    margin: 1rem 0;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white !important;
}

.btn-primary:hover {
    background-color: var(--secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Resources Grid */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0 3rem 0;
}

.resource-card {
    background: #111827;
    /* Dark background */
    border: 1px solid #374151;
    /* Dark gray border */
    border-radius: 12px;
    padding: 1.75rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    overflow: hidden;
}

.resource-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    transition: background 0.3s ease;
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    background: #1f2937;
    /* Slightly lighter dark */
    border-color: #4b5563;
}

.resource-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.resource-card h3 {
    margin: 0 0 0.5rem 0 !important;
    font-size: 1.25rem;
    font-weight: 600;
    color: #ffffff !important;
    /* Very light gray text */
}

.resource-card p {
    margin: 0 !important;
    font-size: 0.95rem;
    color: #e5e7eb !important;
    /* Muted text */
    line-height: 1.6;
}

/* Specific Card Colors (Top Border) */
.resource-card.howto:hover::before {
    background: #3b82f6;
}

/* Blue */
.resource-card.casestudies:hover::before {
    background: #10b981;
}

/* Emerald */
.resource-card.examples:hover::before {
    background: #f97316;
}

/* Orange */
.resource-card.youtube:hover::before {
    background: #ef4444;
}

/* Red */
.resource-card.webinars:hover::before {
    background: #ec4899;
}

/* Pink */
.resource-card.ms-store:hover::before {
    background: #eab308;
}

/* Yellow */
.resource-card.adsk-store:hover::before {
    background: #14b8a6;
}

/* Teal */
.resource-card.contact:hover::before {
    background: #8b5cf6;
}

/* Violet */

/* Purple */

/* Menu Highlight for Resources */
.nav-item a[href*="vcad-resources"] {
    position: relative;
    color: white !important;
    font-weight: 600;
    margin-top: 2rem;
    display: flex;
    /* Ensure alignment */
    align-items: center;
}

/* Active State for Resources: Text Black on White Background */
.nav-item a[href*="vcad-resources"].active {
    color: black !important;
    background-color: white !important;
}

.nav-item a[href*="vcad-resources"]::before {
    content: '';
    display: block;
    /* Forced block */
    flex-shrink: 0;
    /* Prevent collapsing */
    width: 16px;
    height: 16px;
    margin-right: 10px;

    /* Default White Icon */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71'%3E%3C/path%3E%3Cpath d='M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

/* Active State Icon: Switch to Black */
.nav-item a[href*="vcad-resources"].active::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71'%3E%3C/path%3E%3Cpath d='M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71'%3E%3C/path%3E%3C/svg%3E");
    opacity: 1;
}

.nav-item a[href*="vcad-resources"]:hover::before {
    opacity: 1;
}

/* Standard Hover for Resources (Not Active) */
.nav-item a[href*="vcad-resources"]:not(.active):hover {
    color: white !important;
}

/* Hover for Resources (Active) - Stay Black */
.nav-item a[href*="vcad-resources"].active:hover {
    color: black !important;
}