:root {
    --fk-accent: #0d9488;
    --fk-accent-hover: #0f766e;
    --fk-bg: #f5f5f7;
    --fk-surface: #ffffff;
    --fk-border: #e5e7eb;
    --fk-text: #111827;
    --fk-muted: #6b7280;
    --fk-nav-bg: rgba(255, 255, 255, 0.85);
    --fk-radius: 12px;
    --fk-font: 'Inter', system-ui, -apple-system, sans-serif;
}

[data-theme="dark"] {
    --fk-accent: #2dd4bf;
    --fk-accent-hover: #5eead4;
    --fk-bg: #0f1117;
    --fk-surface: #1a1d27;
    --fk-border: #2d3348;
    --fk-text: #f3f4f6;
    --fk-muted: #9ca3af;
    --fk-nav-bg: rgba(15, 17, 23, 0.9);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    font-family: var(--fk-font);
    background-color: var(--fk-bg);
    color: var(--fk-text);
    -webkit-font-smoothing: antialiased;
}

/* Navigation */
.fk-nav {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: var(--fk-nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--fk-border);
}

.fk-nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
}

.fk-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--fk-text);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.fk-brand:hover {
    color: var(--fk-accent);
}

.fk-brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    flex-shrink: 0;
}

.fk-brand-icon img {
    display: block;
    width: 100%;
    height: 100%;
}

.fk-nav-links {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.fk-nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--fk-muted);
    text-decoration: none;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}

.fk-nav-link:hover {
    color: var(--fk-text);
}

.fk-nav-link.active {
    color: var(--fk-accent);
    border-bottom-color: var(--fk-accent);
}

.fk-theme-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 1px solid var(--fk-border);
    border-radius: 8px;
    background: var(--fk-surface);
    color: var(--fk-muted);
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
}

.fk-theme-btn:hover {
    color: var(--fk-text);
    border-color: var(--fk-muted);
}

/* Layout */
.fk-main {
    padding: 1.25rem 0 2rem;
}

.fk-page-title {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

.fk-footer {
    border-top: 1px solid var(--fk-border);
    padding: 1rem 0;
    margin-top: auto;
}

.fk-footer p {
    color: var(--fk-muted);
    font-size: 0.8rem;
    text-align: center;
    margin: 0;
}

.fk-about {
    border-top: 1px solid var(--fk-border);
}

.fk-about-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
    letter-spacing: -0.02em;
}

.fk-about-body {
    padding: 1rem 1.125rem;
}

.fk-about-body p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--fk-muted);
}

/* Cards */
.fk-card,
.category-tile,
.claim-card,
.card {
    background: var(--fk-surface);
    border: 1px solid var(--fk-border);
    border-radius: var(--fk-radius);
    box-shadow: none;
}

.category-tile,
.claim-card {
    transition: border-color 0.15s;
}

a:hover .category-tile,
a:hover .claim-card {
    border-color: var(--fk-accent);
}

.category-tile {
    min-height: 7.5rem;
}

.category-tile-icon {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--fk-accent);
    font-size: 1.2rem;
}

.category-tile .card-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--fk-text);
    line-height: 1.3;
}

.claim-card .card-body {
    padding: 0.875rem 1rem;
}

.claim-card .claim-title {
    color: var(--fk-text);
    font-size: 0.925rem;
    line-height: 1.45;
}

/* Forms */
.form-control,
.form-select {
    background-color: var(--fk-surface);
    border-color: var(--fk-border);
    color: var(--fk-text);
    border-radius: 10px;
    font-size: 0.9rem;
}

.form-control:focus,
.form-select:focus {
    background-color: var(--fk-surface);
    border-color: var(--fk-accent);
    color: var(--fk-text);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--fk-accent) 18%, transparent);
}

.input-group-text {
    background: var(--fk-surface);
    border-color: var(--fk-border);
    color: var(--fk-muted);
    border-radius: 10px 0 0 10px;
}

.btn-primary {
    background-color: var(--fk-accent);
    border-color: var(--fk-accent);
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.9rem;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--fk-accent-hover);
    border-color: var(--fk-accent-hover);
}

.text-primary {
    color: var(--fk-accent) !important;
}

.text-muted {
    color: var(--fk-muted) !important;
}

.text-dark {
    color: var(--fk-text) !important;
}

/* Breadcrumb */
.breadcrumb {
    font-size: 0.8rem;
    margin-bottom: 1rem;
    --bs-breadcrumb-divider-color: var(--fk-muted);
}

.breadcrumb-item a {
    color: var(--fk-muted);
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: var(--fk-accent);
}

.breadcrumb-item.active {
    color: var(--fk-text);
}

/* Status & meta */
.fk-meta-stack {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
}

.fk-status,
.fk-evidence {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--fk-muted);
    letter-spacing: 0.01em;
}

.fk-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

.fk-status--falsch .fk-status-dot { background: #ef4444; }
.fk-status--irrefuehrend .fk-status-dot { background: #f59e0b; }
.fk-status--teilweise_richtig .fk-status-dot { background: #3b82f6; }
.fk-status--unbelegt .fk-status-dot { background: #9ca3af; }
.fk-status--wissenschaftlicher_konsens .fk-status-dot { background: #10b981; }
.fk-status--offene_frage .fk-status-dot { background: #8b5cf6; }

.fk-topic {
    font-size: 0.72rem;
    color: var(--fk-muted);
    font-weight: 500;
}

/* Detail sections */
.fk-section {
    margin-bottom: 1.5rem;
}

.fk-section-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--fk-muted);
    margin: 0 0 0.625rem;
}

.fk-section-body {
    padding: 1rem 1.125rem;
    line-height: 1.6;
    font-size: 0.9rem;
    color: var(--fk-muted);
}

.fk-section-body p:last-child {
    margin-bottom: 0;
}

.fk-answer-card {
    border-left: 3px solid var(--fk-accent);
    padding: 1rem 1.125rem;
    margin-bottom: 1.5rem;
}

.fk-answer-card p:last-child {
    margin-bottom: 0;
    line-height: 1.6;
    font-size: 0.95rem;
}

.fk-claim-title {
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.35;
    margin-bottom: 0.75rem;
}

/* Evidence */
.fk-img-open {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

.evidence-img {
    display: block;
    max-height: 20rem;
    object-fit: contain;
    background: var(--fk-bg);
}

.evidence-card {
    overflow: hidden;
}

.fk-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.fk-lightbox[hidden] {
    display: none !important;
}

.fk-lightbox-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(0, 0, 0, 0.88);
    cursor: zoom-out;
}

.fk-lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
    width: 2.5rem;
    height: 2.5rem;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
}

.fk-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.22);
}

.fk-lightbox-img {
    position: relative;
    z-index: 1;
    max-width: min(100%, 1200px);
    max-height: calc(100vh - 4rem);
    object-fit: contain;
    border-radius: 8px;
}

.fk-lightbox-caption {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    z-index: 2;
    transform: translateX(-50%);
    max-width: min(90%, 40rem);
    margin: 0;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 0.85rem;
    text-align: center;
}

body.fk-lightbox-open {
    overflow: hidden;
}

/* Accordion */
.fk-section .accordion {
    margin-top: 0;
}

.fk-accordion {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.fk-accordion .accordion-item {
    background: var(--fk-surface);
    border: 1px solid var(--fk-border);
    border-radius: var(--fk-radius);
    overflow: hidden;
}

.fk-accordion .accordion-button {
    background: var(--fk-surface);
    color: var(--fk-text);
    font-size: 0.875rem;
    box-shadow: none !important;
    border-radius: var(--fk-radius);
}

.fk-accordion .accordion-button:not(.collapsed) {
    background: color-mix(in srgb, var(--fk-accent) 8%, var(--fk-surface));
    color: var(--fk-text);
    border-radius: var(--fk-radius) var(--fk-radius) 0 0;
}

.fk-accordion .accordion-body {
    color: var(--fk-muted);
    font-size: 0.875rem;
    background: var(--fk-surface);
}

.accordion-item {
    background: var(--fk-surface);
    border-color: var(--fk-border) !important;
}

.accordion-button {
    background: var(--fk-surface);
    color: var(--fk-text);
    font-size: 0.875rem;
    box-shadow: none !important;
}

.accordion-button:not(.collapsed) {
    background: color-mix(in srgb, var(--fk-accent) 8%, var(--fk-surface));
    color: var(--fk-text);
}

.accordion-body {
    color: var(--fk-muted);
    font-size: 0.875rem;
}

/* Tags */
.fk-tag {
    display: inline-block;
    font-size: 0.72rem;
    color: var(--fk-muted);
    border: 1px solid var(--fk-border);
    border-radius: 999px;
    padding: 0.15rem 0.55rem;
    background: var(--fk-surface);
}

/* Source links */
.fk-source-link {
    color: var(--fk-text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
}

.fk-source-link:hover {
    color: var(--fk-accent);
}

@media (max-width: 576px) {
    .category-tile {
        min-height: 6.5rem;
    }

    .category-tile-icon {
        width: 2rem;
        height: 2rem;
        font-size: 1rem;
    }

    .category-tile .card-title {
        font-size: 0.8rem;
    }

    .fk-nav-link {
        font-size: 0.85rem;
    }
}
