/* Test Fire Studio Documentation Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #dc2626;
    --primary-dark: #b91c1c;
    --text: #1f2937;
    --text-light: #6b7280;
    --bg: #ffffff;
    --bg-alt: #f9fafb;
    --bg-code: #111827;
    --border: #e5e7eb;
    --green: #10b981;
    --blue: #3b82f6;
    --yellow: #f59e0b;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header */
header {
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 24px;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    font-size: 1.5rem;
}

.nav-links {
    display: flex;
    gap: 24px;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--primary);
}

/* Main content */
main {
    padding: 48px 0;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 48px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-top: 32px;
    margin-bottom: 12px;
}

h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-top: 24px;
    margin-bottom: 8px;
}

p {
    margin-bottom: 16px;
    color: var(--text);
}

.subtitle {
    color: var(--text-light);
    font-size: 1.125rem;
    margin-bottom: 32px;
}

/* Links */
a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Lists */
ul, ol {
    margin-bottom: 16px;
    padding-left: 24px;
}

li {
    margin-bottom: 8px;
}

/* Code */
code {
    font-family: 'SF Mono', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.875em;
    background: var(--bg-alt);
    padding: 2px 6px;
    border-radius: 4px;
}

pre {
    background: var(--bg-code);
    color: #e5e7eb;
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 16px;
}

pre code {
    background: none;
    padding: 0;
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Cards */
.card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.card-link {
    display: block;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    text-decoration: none;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.card-link:hover {
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--primary);
}

.card-link h3 {
    margin-top: 0;
    color: var(--text);
}

.card-link p {
    color: var(--text-light);
    margin-bottom: 0;
}

/* Highlight boxes */
.highlight {
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.highlight-blue {
    background: #eff6ff;
    border-left: 4px solid var(--blue);
}

.highlight-yellow {
    background: #fffbeb;
    border-left: 4px solid var(--yellow);
}

.highlight-green {
    background: #ecfdf5;
    border-left: 4px solid var(--green);
}

.highlight-red {
    background: #fef2f2;
    border-left: 4px solid var(--primary);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 16px;
    font-size: 0.875rem;
}

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

th {
    font-weight: 600;
    background: var(--bg-alt);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
}

.badge-primary {
    background: var(--primary);
    color: white;
}

.badge-green {
    background: #d1fae5;
    color: #065f46;
}

.badge-blue {
    background: #dbeafe;
    color: #1e40af;
}

.badge-yellow {
    background: #fef3c7;
    color: #92400e;
}

.badge-red {
    background: #fee2e2;
    color: #991b1b;
}

.badge-gray {
    background: #f3f4f6;
    color: #374151;
}

/* Method badges */
.method {
    display: inline-block;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 4px;
    font-family: monospace;
}

.method-get { background: #d1fae5; color: #065f46; }
.method-post { background: #dbeafe; color: #1e40af; }
.method-delete { background: #fee2e2; color: #991b1b; }
.method-put { background: #fef3c7; color: #92400e; }

/* Steps */
.steps {
    counter-reset: step;
}

.step {
    position: relative;
    padding-left: 48px;
    margin-bottom: 32px;
}

.step::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
}

/* Footer */
footer {
    padding: 32px 0;
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-light);
    font-size: 0.875rem;
}

footer a {
    color: var(--text-light);
}

footer a:hover {
    color: var(--text);
}

.footer-links {
    margin-bottom: 12px;
}

.footer-links a {
    margin: 0 12px;
}

/* Responsive */
@media (max-width: 640px) {
    .container {
        padding: 0 16px;
    }

    .header-content {
        padding: 0 16px;
    }

    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.25rem;
    }

    .nav-links {
        gap: 16px;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }
}

/* Sidebar nav for docs */
.doc-nav {
    background: var(--bg-alt);
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 24px;
}

.doc-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.doc-nav li {
    margin-bottom: 8px;
}

.doc-nav a {
    color: var(--text);
    font-weight: 500;
}

.doc-nav a:hover {
    color: var(--primary);
}

.doc-nav a.active {
    color: var(--primary);
}

/* Copy button */
.code-block {
    position: relative;
}

.copy-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #9ca3af;
    padding: 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.875rem;
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Endpoint styling */
.endpoint {
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
}

.endpoint-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
}

.endpoint-body {
    padding: 16px;
}
