/* KitsuneDB Documentation - Module Styles (for iframe) */

:root {
    --primary-color: #ff6b35;
    --primary-dark: #e55a2b;
    --secondary-color: #2c3e50;
    --bg-color: #f8f9fa;
    --text-color: #333;
    --text-light: #666;
    --border-color: #e1e4e8;
    --code-bg: #282c34;
    --code-text: #abb2bf;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: #fff;
    padding: 30px 40px;
}

/* Page Header */
.page-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.page-header h1 {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 8px;
}

.page-header .subtitle {
    font-size: 1rem;
    color: var(--text-light);
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-size: 0.85rem;
}

.breadcrumb a {
    color: var(--text-light);
}

.breadcrumb span {
    margin: 0 8px;
    color: var(--text-light);
}

/* Sections */
section {
    margin-bottom: 40px;
}

section h2 {
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

section h3 {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin: 25px 0 12px;
}

section h4 {
    font-size: 1rem;
    color: var(--text-light);
    margin: 18px 0 8px;
}

p {
    margin-bottom: 12px;
}

/* Code Blocks */
pre {
    background: var(--code-bg);
    color: var(--code-text);
    padding: 18px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 15px 0;
    font-family: 'Fira Code', 'JetBrains Mono', Consolas, monospace;
    font-size: 0.85rem;
    line-height: 1.5;
}

code {
    font-family: 'Fira Code', 'JetBrains Mono', Consolas, monospace;
}

:not(pre) > code {
    background: #f0f0f0;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.85em;
    color: var(--primary-dark);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

th, td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background: var(--secondary-color);
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
}

tr:hover {
    background: #f8f9fa;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 600;
}

.badge-success { background: #d4edda; color: #155724; }
.badge-warning { background: #fff3cd; color: #856404; }
.badge-danger { background: #f8d7da; color: #721c24; }
.badge-info { background: #d1ecf1; color: #0c5460; }
.badge-primary { background: #ffe4d6; color: #a63d16; }

/* Cards */
.card {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 20px;
    margin: 15px 0;
    border-left: 4px solid var(--primary-color);
}

.card h3 {
    margin-top: 0;
    font-size: 1.1rem;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.feature-card {
    background: #f8f9fa;
    padding: 18px;
    border-radius: 6px;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid var(--border-color);
}

.feature-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.feature-card .icon {
    font-size: 1.8rem;
    margin-bottom: 8px;
}

.feature-card h4 {
    margin: 0 0 8px;
    color: var(--secondary-color);
    font-size: 1rem;
}

.feature-card p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Alert Boxes */
.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin: 15px 0;
    display: flex;
    align-items: flex-start;
}

.alert .icon {
    font-size: 1.1rem;
    margin-right: 10px;
    flex-shrink: 0;
}

.alert-info {
    background: #e7f5ff;
    border-left: 4px solid var(--info-color);
}

.alert-warning {
    background: #fff9e6;
    border-left: 4px solid var(--warning-color);
}

.alert-success {
    background: #e6f7e6;
    border-left: 4px solid var(--success-color);
}

.alert-danger {
    background: #ffe6e6;
    border-left: 4px solid var(--danger-color);
}

/* Lists */
ul, ol {
    margin: 12px 0;
    padding-left: 22px;
}

li {
    margin-bottom: 6px;
}

/* Links */
a {
    color: var(--primary-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Footer Navigation */
.page-footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.page-footer a {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 4px;
    transition: background 0.2s;
}

.page-footer a:hover {
    background: #e9ecef;
    text-decoration: none;
}

.page-footer .icon {
    margin: 0 5px;
}

/* Copy button for code */
.code-block {
    position: relative;
}

.copy-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    padding: 4px 8px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.75rem;
    opacity: 0;
    transition: opacity 0.2s;
}

.code-block:hover .copy-btn {
    opacity: 1;
}

.copy-btn:hover {
    background: rgba(255,255,255,0.25);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

