@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/inter-latin-400-normal.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("../fonts/inter-latin-500-normal.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("../fonts/inter-latin-600-normal.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../fonts/inter-latin-700-normal.woff2") format("woff2");
}

@font-face {
    font-family: "IBM Plex Mono";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2");
}

@font-face {
    font-family: "IBM Plex Mono";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("../fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2");
}

:root {
    --bg: #0a0a0c;
    --bg-deep: #050506;
    --surface: #121216;
    --line: #1e1e23;
    --line-strong: #2a2a31;
    --line-bright: #3a3a42;
    --text: #f5f5f7;
    --text-soft: #9a9aa3;
    --text-faint: #6e6e78;
    --brand: var(--ghost-accent-color, #c6ff4a);
    --neon-lime: #c6ff4a;
    --neon-cyan: #4ae8ff;
    --neon-magenta: #ff4ad8;
    --neon-violet: #a78bff;
    --neon-amber: #ffb02e;
    --neon-green: #3df58c;
    --font-base: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --font-sans: var(--gh-font-body, var(--font-base));
    --font-heading: var(--gh-font-heading, var(--font-base));
    --font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

* {
    box-sizing: border-box;
}

html {
    background: var(--bg);
}

body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.site {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Kategoriefarben: Accent pro Tag-Slug, Fallback Markenfarbe */
.feed-item,
.article,
.archive-header {
    --accent: var(--brand);
}

.tag-crm { --accent: var(--neon-lime); }
.tag-customer-experience, .tag-cx { --accent: var(--neon-cyan); }
.tag-sales, .tag-vertrieb { --accent: var(--neon-magenta); }
.tag-service { --accent: var(--neon-violet); }
.tag-marketing { --accent: var(--neon-amber); }
.tag-ki, .tag-ai, .tag-kuenstliche-intelligenz { --accent: var(--neon-green); }

/* Header */

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 0;
    border-bottom: 1px solid var(--line);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
}

.brand-glyph {
    display: block;
    color: var(--brand);
    flex-shrink: 0;
}

.brand-word {
    font-family: var(--font-mono);
    font-size: 19px;
    font-weight: 500;
    letter-spacing: -0.4px;
    color: var(--text);
    white-space: nowrap;
}

.brand-tld {
    color: var(--brand);
}

.brand-logo {
    height: 28px;
    width: auto;
}

.brand-footer .brand-glyph {
    width: 20px;
    height: 20px;
}

.brand-footer .brand-word {
    font-size: 16px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.site-nav .nav {
    display: flex;
    align-items: center;
    gap: 22px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-nav .nav a {
    font-size: 14px;
    color: var(--text-soft);
    transition: color 0.15s ease;
}

.site-nav .nav a:hover,
.site-nav .nav .nav-current a {
    color: var(--text);
}

/* Buttons */

.btn {
    display: inline-block;
    padding: 9px 22px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    cursor: pointer;
    border: 0;
    font-family: var(--font-sans);
}

.btn-accent {
    background: var(--brand);
    color: var(--bg);
}

.btn-accent:hover {
    filter: brightness(1.1);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--line-bright);
    color: var(--text);
}

.btn-outline:hover {
    border-color: var(--text-soft);
}

/* Feed */

.site-main {
    padding: 40px 0 64px;
    min-height: 50vh;
}

.post-feed {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 36px 32px;
}

.feed-item {
    grid-column: span 2;
    display: flex;
    align-items: center;
    gap: 28px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--line);
}

.feed-item-image {
    flex: 0 0 260px;
    height: 160px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-left: 4px solid var(--accent);
    overflow: hidden;
    position: relative;
}

.feed-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-placeholder {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.placeholder-ring {
    position: absolute;
    right: -18%;
    top: -25%;
    width: 55%;
    aspect-ratio: 1;
    border-radius: 50%;
    border: 1px solid var(--accent);
}

.placeholder-square {
    position: absolute;
    left: 14%;
    bottom: 12%;
    width: 18%;
    aspect-ratio: 1;
    border: 1px solid var(--line-bright);
    transform: rotate(45deg);
}

.feed-item-content {
    min-width: 0;
}

.post-tag {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--accent);
    letter-spacing: 0.2px;
}

.post-tag:hover {
    text-decoration: underline;
}

.feed-item-title {
    margin: 8px 0 8px;
    font-family: var(--font-heading);
    font-size: 21px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: -0.2px;
}

.feed-item-title a:hover {
    color: var(--accent);
}

.feed-item-excerpt {
    display: none;
    margin: 0 0 14px;
    font-size: 15px;
    color: var(--text-soft);
    max-width: 560px;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.author-avatar img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line-strong);
}

.post-meta-text {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-faint);
}

/* Startseite: Hero + zweispaltiges Featured-Grid (nur Seite 1) */

.home-template:not(.paged) .feed-item:nth-child(1) {
    flex-direction: column;
    align-items: stretch;
    gap: 24px;
}

.home-template:not(.paged) .feed-item:nth-child(1) .feed-item-image {
    flex: none;
    height: 420px;
}

.home-template:not(.paged) .feed-item:nth-child(1) .feed-item-title {
    font-size: 40px;
    letter-spacing: -0.5px;
}

.home-template:not(.paged) .feed-item:nth-child(1) .feed-item-excerpt {
    display: block;
}

.home-template:not(.paged) .feed-item:nth-child(2),
.home-template:not(.paged) .feed-item:nth-child(3) {
    grid-column: span 1;
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
}

.home-template:not(.paged) .feed-item:nth-child(2) .feed-item-image,
.home-template:not(.paged) .feed-item:nth-child(3) .feed-item-image {
    flex: none;
    height: 230px;
}

/* Mehr laden */

.load-more-wrap {
    text-align: center;
    padding: 40px 0 8px;
}

/* Autorenzeile */

.authors-strip {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 22px;
    margin-top: 48px;
    padding: 24px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.authors-label {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-faint);
}

.author-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.author-chip-image,
.author-chip-fallback {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line-strong);
}

.author-chip-fallback {
    display: inline-block;
    background: var(--surface);
    position: relative;
}

.author-chip-fallback::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 8px;
    height: 8px;
    margin: -4px 0 0 -4px;
    background: var(--brand);
}

.author-chip-name {
    font-size: 14px;
    font-weight: 500;
}

.author-chip:hover .author-chip-name {
    color: var(--brand);
}

/* Artikelseite */

.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0;
    background: var(--accent);
    z-index: 50;
    transition: width 0.08s linear;
}

.post-hero {
    display: grid;
    margin: 28px 0 8px;
}

.post-hero-media {
    grid-area: 1 / 1;
    width: 64%;
    align-self: center;
    background: var(--surface);
    border: 1px solid var(--line);
}

.post-hero-media img {
    width: 100%;
    display: block;
}

.post-hero-card {
    grid-area: 1 / 1;
    justify-self: end;
    align-self: center;
    width: 53%;
    z-index: 2;
    background: var(--surface);
    border: 2px solid var(--accent);
    padding: 32px 34px;
}

.post-hero-title {
    margin: 14px 0 0;
    font-family: var(--font-heading);
    font-size: 34px;
    font-weight: 700;
    line-height: 1.18;
    letter-spacing: -0.5px;
}

.post-hero-excerpt {
    margin: 16px 0 0;
    font-size: 16px;
    line-height: 1.55;
    color: var(--text-soft);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 36px;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.meta-label {
    display: block;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--text-faint);
    margin-bottom: 6px;
}

.meta-value {
    font-size: 14px;
    color: var(--text);
}

.meta-author {
    color: var(--accent);
}

.meta-author:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.article-header {
    max-width: 760px;
    margin: 24px auto 0;
    padding-top: 20px;
    border-top: 2px solid var(--accent);
}

.article-kicker {
    font-size: 13px;
}

.article-title {
    margin: 12px 0 16px;
    font-family: var(--font-heading);
    font-size: 44px;
    font-weight: 700;
    line-height: 1.16;
    letter-spacing: -0.6px;
}

.article-excerpt {
    margin: 0 0 20px;
    font-size: 19px;
    line-height: 1.55;
    color: var(--text-soft);
    padding-left: 16px;
    border-left: 2px solid var(--line-bright);
}

.article-meta {
    padding-top: 4px;
}

.article-image {
    margin: 36px 0;
    border: 1px solid var(--line);
    border-left: 4px solid var(--accent);
    background: var(--surface);
}

.article-image img {
    width: 100%;
}

.article-image figcaption {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-faint);
    padding: 10px 14px;
    border-top: 1px solid var(--line);
}

.article-content {
    max-width: 760px;
    margin: 32px auto 0;
    font-size: 17px;
    line-height: 1.75;
}

.gh-content > * + * {
    margin-top: 1.4em;
}

.gh-content h1,
.gh-content h2,
.gh-content h3,
.gh-content h4 {
    font-family: var(--font-heading);
}

.gh-content h2 {
    font-size: 28px;
    line-height: 1.3;
    letter-spacing: -0.3px;
    margin-top: 2em;
}

.gh-content h2::before {
    content: "## ";
    font-family: var(--font-mono);
    font-weight: 400;
    color: var(--accent);
}

.gh-content h3 {
    font-size: 22px;
    line-height: 1.35;
    margin-top: 1.8em;
}

.gh-content h3::before {
    content: "# ";
    font-family: var(--font-mono);
    font-weight: 400;
    color: var(--accent);
}

.article-content > p:first-of-type::first-letter {
    float: left;
    font-family: var(--font-heading);
    font-size: 64px;
    font-weight: 700;
    line-height: 0.82;
    padding: 6px 12px 0 0;
    color: var(--accent);
}

.gh-content a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.gh-content strong {
    color: var(--text);
    font-weight: 600;
}

.gh-content blockquote {
    position: relative;
    margin: 1.8em 0;
    padding: 20px 24px 20px 56px;
    border-left: 3px solid var(--accent);
    background: var(--surface);
    color: var(--text);
    font-family: var(--font-heading);
    font-size: 21px;
    line-height: 1.45;
}

.gh-content blockquote::before {
    content: "\201C";
    position: absolute;
    left: 14px;
    top: 6px;
    font-family: var(--font-heading);
    font-size: 52px;
    line-height: 1;
    color: var(--accent);
}

.gh-content ul {
    list-style: none;
    padding-left: 0;
}

.gh-content ul > li {
    position: relative;
    padding-left: 26px;
}

.gh-content ul > li::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 0.66em;
    width: 8px;
    height: 8px;
    background: var(--accent);
}

.gh-content ol {
    list-style: none;
    counter-reset: gh-ol;
    padding-left: 0;
}

.gh-content ol > li {
    position: relative;
    padding-left: 36px;
    counter-increment: gh-ol;
}

.gh-content ol > li::before {
    content: counter(gh-ol);
    position: absolute;
    left: 0;
    top: 0.1em;
    font-family: var(--font-mono);
    font-size: 0.85em;
    font-weight: 500;
    color: var(--accent);
}

.gh-content code {
    font-family: var(--font-mono);
    font-size: 0.88em;
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 2px 6px;
}

.gh-content pre {
    background: var(--surface);
    border: 1px solid var(--line);
    padding: 18px 20px;
    overflow-x: auto;
    font-size: 14px;
    line-height: 1.6;
}

.gh-content pre code {
    background: none;
    border: 0;
    padding: 0;
}

.gh-content hr {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 2.5em 0;
}

.gh-content figcaption {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-faint);
    text-align: center;
    margin-top: 10px;
}

.gh-content li + li {
    margin-top: 0.5em;
}

.gh-content li > ul,
.gh-content li > ol {
    margin-top: 0.5em;
}

.kg-width-wide {
    position: relative;
    width: 1120px;
    max-width: calc(100vw - 48px);
    margin-left: 50%;
    transform: translateX(-50%);
}

.kg-width-full {
    position: relative;
    width: 100vw;
    max-width: 100vw;
    margin-left: 50%;
    transform: translateX(-50%);
}

.article-footer {
    max-width: 760px;
    margin: 56px auto 0;
}

.author-card {
    display: flex;
    gap: 18px;
    padding: 22px 24px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-left: 3px solid var(--accent);
}

.author-card-image img,
.author-card-fallback {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    flex-shrink: 0;
}

.author-card-fallback {
    display: block;
    background: var(--bg);
    position: relative;
}

.author-card-fallback::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 12px;
    height: 12px;
    margin: -6px 0 0 -6px;
    background: var(--accent);
}

.author-card-label {
    display: block;
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--text-faint);
    margin-bottom: 4px;
}

.author-card-name {
    font-family: var(--font-heading);
    font-size: 19px;
    font-weight: 600;
}

.author-card-name:hover {
    color: var(--accent);
}

.author-card-bio {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.55;
    color: var(--text-soft);
}

.author-card-links {
    display: flex;
    gap: 16px;
    margin-top: 12px;
}

.author-card-links a {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--accent);
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
}

/* Weiterlesen */

.related {
    margin-top: 72px;
    padding-top: 32px;
    border-top: 1px solid var(--line);
}

.related-title {
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-faint);
    margin: 0 0 28px;
}

/* Archiv (Tag/Autor) */

.archive-header {
    max-width: 760px;
    margin: 16px 0 44px;
}

.archive-title {
    margin: 10px 0 12px;
    font-family: var(--font-heading);
    font-size: 38px;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.archive-description {
    margin: 0;
    font-size: 16px;
    color: var(--text-soft);
}

.author-header {
    display: flex;
    align-items: center;
    gap: 24px;
}

.author-image,
.author-image-fallback {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    flex-shrink: 0;
}

.author-links {
    display: flex;
    gap: 16px;
    margin-top: 10px;
}

.author-links a {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--brand);
}

/* Footer */

.site-footer {
    background: var(--bg-deep);
    border-top: 1px solid var(--line);
    margin: 0 -24px;
    padding: 44px 24px 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--line);
}

.brand-footer .brand-title {
    font-size: 17px;
}

.footer-description {
    margin: 12px 0 16px;
    font-size: 14px;
    color: var(--text-soft);
    max-width: 320px;
}

.footer-nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-nav .nav {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-nav a {
    font-size: 13px;
    color: var(--text-faint);
}

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

.newsletter-title {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 600;
}

.newsletter-text {
    margin: 0 0 14px;
    font-size: 13px;
    color: var(--text-soft);
}

.newsletter-form {
    display: flex;
}

.newsletter-input {
    flex: 1;
    min-width: 0;
    background: var(--surface);
    border: 1px solid var(--line-strong);
    border-right: 0;
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 14px;
    padding: 10px 14px;
    outline: none;
}

.newsletter-input:focus {
    border-color: var(--brand);
}

.newsletter-input::placeholder {
    color: var(--text-faint);
}

.newsletter-success,
.newsletter-error {
    display: none;
    margin: 10px 0 0;
    font-size: 13px;
}

.newsletter-success {
    color: var(--neon-lime);
}

.newsletter-error {
    color: #ff6b6b;
}

.newsletter form.success ~ .newsletter-success,
.newsletter form.success + .newsletter-success {
    display: block;
}

.newsletter form.error + .newsletter-success + .newsletter-error,
.newsletter form.error ~ .newsletter-error {
    display: block;
}

.footer-meta {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 18px;
    font-size: 12.5px;
    color: var(--text-faint);
}

.footer-meta a {
    color: var(--text-soft);
}

/* Responsive */

@media (max-width: 860px) {
    .site-header {
        flex-direction: column;
        gap: 14px;
        padding: 20px 0;
    }

    .home-template:not(.paged) .feed-item:nth-child(2),
    .home-template:not(.paged) .feed-item:nth-child(3) {
        grid-column: span 2;
    }

    .home-template:not(.paged) .feed-item:nth-child(1) .feed-item-image {
        height: 260px;
    }

    .home-template:not(.paged) .feed-item:nth-child(1) .feed-item-title {
        font-size: 30px;
    }

    .article-title {
        font-size: 31px;
    }

    .post-hero {
        display: block;
    }

    .post-hero-media {
        width: 100%;
    }

    .post-hero-card {
        width: auto;
        justify-self: stretch;
        margin: -56px 16px 0;
        padding: 26px 24px;
    }

    .post-hero-title {
        font-size: 28px;
    }

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

@media (max-width: 620px) {
    .feed-item {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }

    .feed-item-image {
        flex: none;
        height: 200px;
    }

    .site-nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 14px;
    }

    .author-header {
        flex-direction: column;
        align-items: flex-start;
    }
}
