:root {
    --bg-color: #ffffff;
    --text-color: #24292e;
    --accent-color: #0366d6;
    --border-color: #e1e4e8;
    --muted-color: #586069;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
    font-size: 16px;
}

/* Navigation */
nav {
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    background-color: #f6f8fa;
    gap: 1rem;
}

nav .logo {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-color);
    text-decoration: none;
}

nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    list-style: none;
    gap: 0.1rem 0.5rem;
}

nav ul li a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
}

nav ul li a:hover {
    text-decoration: underline;
}

/* Nav dropdowns (category menus) */
.nav-dropdown {
    position: relative;
}

.nav-cat-label {
    cursor: pointer;
    color: var(--accent-color);
    font-weight: 500;
    user-select: none;
}

.nav-cat-label::after {
    content: " \25BE";
    font-size: 0.7em;
}

.nav-cat-label:hover {
    text-decoration: underline;
}

.nav-dropdown .dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 0;
    padding-top: 0.5rem;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-width: 280px;
    padding-bottom: 0.5rem;
    gap: 0;
    z-index: 1000;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.open .dropdown-menu {
    display: block;
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu li a {
    display: block;
    padding: 0.5rem 1.25rem;
    white-space: nowrap;
    font-weight: 400;
}

.dropdown-menu li a:hover {
    background-color: #f6f8fa;
    text-decoration: none;
}

/* Container */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

/* Typography */
h1, h2, h3, h4 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.25;
}

h1 {
    font-size: 2rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.3em;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.3em;
}

h3 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1rem;
}

ul, ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

li {
    margin-bottom: 0.25rem;
}

a {
    color: var(--accent-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Sections */
section {
    margin-bottom: 2.5rem;
}

/* Hero */
.hero {
    margin-bottom: 3rem;
}

.hero h1 {
    border: none;
    font-size: 2.5rem;
}

.hero p {
    font-size: 1.25rem;
    color: var(--muted-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 5px 16px;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    white-space: nowrap;
    vertical-align: middle;
    cursor: pointer;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-color);
    background-color: #fafbfc;
    text-decoration: none;
}

.btn:hover {
    background-color: #f3f4f6;
    text-decoration: none;
}

/* Citations & Code block styling */
blockquote {
    padding: 0.5rem 1rem;
    color: var(--muted-color);
    border-left: 0.25em solid var(--border-color);
    background-color: #f8f9fa;
    margin: 1rem 0;
    font-style: italic;
}

code {
    font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 85%;
    background-color: rgba(27, 31, 35, 0.05);
    padding: 0.2em 0.4em;
    border-radius: 6px;
}

.repo-meta {
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.8;
}

.badges {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

/* Tables styling */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.95rem;
}

th, td {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    text-align: left;
}

th {
    background-color: #f6f8fa;
    font-weight: 600;
}

tr:nth-child(even) {
    background-color: #fafbfc;
}

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

.mobile-only { display: none; }

/* Mobile Responsive */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
        text-align: center;
    }
    nav ul {
        margin-top: 1rem;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    .desktop-only {
        display: none;
    }
    .mobile-only {
        display: inline;
    }
    .nav-dropdown .dropdown-menu {
        position: static;
        box-shadow: none;
        border: none;
        margin-top: 0.25rem;
        padding-left: 1rem;
    }
    .nav-dropdown:hover .dropdown-menu {
        display: none;
    }
    .nav-dropdown.open .dropdown-menu {
        display: block;
    }
}

/* FAQ Accordion Styling */
.faq-section {
    margin-top: 3.5rem;
    margin-bottom: 3.5rem;
}

.faq-item {
    border: 1px solid var(--border-color);
    border-radius: 6px;
    margin-bottom: 1rem;
    background-color: #fafbfc;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.faq-item:hover {
    border-color: #c8ccd0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.faq-question {
    width: 100%;
    padding: 1.1rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    outline: none;
    text-align: left;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-color);
    cursor: pointer;
    transition: color 0.2s ease;
}

.faq-question:hover {
    color: var(--accent-color);
}

.faq-question::after {
    content: '\25BC'; /* Downward black triangle */
    font-size: 0.75rem;
    color: var(--muted-color);
    transition: transform 0.3s ease;
    margin-left: 1rem;
}

.faq-item.active {
    background-color: #ffffff;
    border-color: var(--border-color);
}

.faq-item.active .faq-question::after {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), padding 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 1.25rem;
    border-top: 0px solid var(--border-color);
}

.faq-item.active .faq-answer {
    max-height: 500px; /* Large enough for text */
    padding: 1.1rem 1.25rem;
    border-top: 1px solid var(--border-color);
}

.faq-answer p {
    margin-bottom: 0.75rem;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

