/* Minimal Dark Theme for Ghost */

/* Reset and Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

ul {
    list-style: none;
}

li {
    list-style: none;
}

:root {
    /* Elegant dark mode colors - lighter and more refined */
    --bg-primary: #151515;
    --bg-secondary: #1f1f1f;
    --text-primary: #e8e8e8;
    --text-secondary: #b0b0b0;
    --text-muted: #777;
    --border-color: #2a2a2a;
    --accent-color: #8b5cf6;
    --link-color: #8b5cf6;
    --link-hover: #a78bfa;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* Terminal Background Animation */
.terminal-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    opacity: 0.12;
}

.terminal-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.terminal-line {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Courier New', monospace;
    font-size: 0.875rem;
    color: #00ff41;
    opacity: 0.8;
    line-height: 1.5;
    white-space: nowrap;
    animation: fadeIn 0.5s ease-in;
    text-shadow: 0 0 5px rgba(0, 255, 65, 0.3);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 0.8;
    }
}

/* Ensure content is above terminal animation */
.site {
    position: relative;
    z-index: 1;
    background-color: transparent;
}

/* Site Container */
.site {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.site-content {
    flex: 1;
}

/* Header */
.gh-head {
    background-color: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 2rem 0;
}

.gh-head-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.gh-head-logo {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s;
}

.gh-head-logo:hover {
    color: var(--link-hover);
}

.gh-head-logo img {
    max-height: 40px;
    width: auto;
}

.gh-head-menu {
    flex: 1;
    display: flex;
    align-items: center;
}

.gh-head-menu ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

.gh-head-menu li {
    list-style: none;
    margin: 0;
    padding: 0;
    display: inline-block;
}

.gh-head-menu li::before,
.gh-head-menu li::after,
.gh-head-menu li::marker {
    display: none;
    content: none;
}

.gh-head-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
    display: inline-block;
}

.gh-head-menu a:hover {
    color: var(--link-hover);
}

.gh-head-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.gh-head-members {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.gh-head-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.gh-head-link:hover {
    color: var(--link-hover);
}

.gh-head-btn {
    padding: 0.5rem 1.25rem;
    background-color: var(--accent-color);
    color: #fff;
    border: 1px solid var(--accent-color);
    border-radius: 4px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s;
    white-space: nowrap;
}

.gh-head-btn:hover {
    background-color: var(--link-hover);
    border-color: var(--link-hover);
    border-color: var(--text-secondary);
    color: var(--bg-primary);
}

.gh-icon-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.gh-icon-btn:hover {
    color: var(--text-primary);
}

.gh-icon-btn svg {
    width: 20px;
    height: 20px;
}

/* Main Content */
.site-main {
    padding: 5rem 0;
}

.gh-canvas {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Home Intro Section */
.home-intro {
    margin-bottom: 4rem;
    text-align: center;
}

.intro-title {
    margin-bottom: 1.5rem;
}

.intro-title h1 {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
    margin: 0;
    letter-spacing: -0.02em;
}

.intro-tagline {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    font-weight: 400;
    letter-spacing: 0.01em;
}

.site-description {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
}

/* Subscribe Section */
.subscribe-section {
    margin-top: 2rem;
    margin-bottom: 3rem;
    display: flex;
    justify-content: center;
}

.subscribe-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
}

.subscribe-email {
    flex: 1;
    min-width: 250px;
    padding: 0.875rem 1.25rem;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, background-color 0.2s;
}

.subscribe-email::placeholder {
    color: var(--text-muted);
}

.subscribe-email:focus {
    outline: none;
    border-color: var(--accent-color);
    background-color: var(--bg-primary);
}

.subscribe-button {
    padding: 0.875rem 2rem;
    background-color: var(--accent-color);
    color: #fff;
    border: 1px solid var(--accent-color);
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s;
    white-space: nowrap;
}

.subscribe-button:hover {
    background-color: var(--link-hover);
    border-color: var(--link-hover);
    color: #fff;
}

.subscribe-button:active {
    transform: translateY(1px);
}

.subscribe-button .loader,
.subscribe-button .success {
    display: none;
}

.subscribe-form.loading .subscribe-button .default {
    display: none;
}

.subscribe-form.loading .subscribe-button .loader {
    display: inline;
}

.subscribe-form.success .subscribe-button .default,
.subscribe-form.success .subscribe-button .loader {
    display: none;
}

.subscribe-form.success .subscribe-button .success {
    display: inline;
}

/* Feed Divider */
.feed-divider {
    margin: 5rem 0;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--border-color) 20%, var(--border-color) 80%, transparent);
    position: relative;
}

.feed-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 4px;
    height: 4px;
    background-color: var(--border-color);
    border-radius: 50%;
}

/* Post Feed */
.post-feed {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    margin-top: 2rem;
}

.feed {
    position: relative;
}

.feed-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-bottom: 2rem;
}

.feed:not(:last-child) .feed-wrapper {
    border-bottom: 1px solid var(--border-color);
}

.feed-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    text-decoration: none;
    cursor: pointer;
}

.feed-link:hover ~ .feed-wrapper .feed-title {
    color: var(--link-hover);
}

.feed-title {
    font-size: 1.75rem;
    font-weight: 600;
    line-height: 1.3;
    margin: 0;
    color: var(--text-primary);
    transition: color 0.2s;
}

.feed-excerpt {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

.feed-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.feed-date {
    color: var(--text-muted);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.feed-meta-separator {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.feed-reading-time {
    color: var(--text-muted);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.no-posts {
    text-align: center;
    color: var(--text-secondary);
    padding: 4rem 0;
    font-size: 1.125rem;
}

/* Single Post */
.single {
    padding-bottom: 5rem;
}

.single-header {
    margin-bottom: 4rem;
}

.feed-header {
    text-align: center;
    margin-bottom: 4rem;
}

.feed-header-title {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.single-title {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.single-excerpt {
    font-size: 1.25rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.single-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.single-meta-date {
    color: var(--text-muted);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.single-meta-separator {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.single-meta-reading-time {
    color: var(--text-muted);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.single-media {
    margin: 2rem 0;
}

.single-media img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

.single-media figcaption {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    text-align: center;
}

.single-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-primary);
}

.single-content h1,
.single-content h2,
.single-content h3,
.single-content h4,
.single-content h5,
.single-content h6 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
}

.single-content h1 { font-size: 2rem; }
.single-content h2 { font-size: 1.75rem; }
.single-content h3 { font-size: 1.5rem; }
.single-content h4 { font-size: 1.25rem; }

.single-content p {
    margin-bottom: 1.75rem;
    line-height: 1.85;
}

.single-content a {
    color: var(--link-color);
    text-decoration: underline;
    text-decoration-color: var(--text-muted);
    transition: color 0.2s, text-decoration-color 0.2s;
}

.single-content a:hover {
    color: var(--link-hover);
    text-decoration-color: var(--link-hover);
}

.single-content ul,
.single-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.single-content li {
    margin-bottom: 0.5rem;
}

.single-content blockquote {
    border-left: 3px solid var(--border-color);
    padding-left: 1.5rem;
    margin: 2rem 0;
    color: var(--text-secondary);
    font-style: italic;
}

.single-content code {
    background-color: var(--bg-secondary);
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-size: 0.9em;
    color: var(--text-primary);
}

.single-content pre {
    background-color: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 4px;
    overflow-x: auto;
    margin: 2rem 0;
}

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

.single-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 2rem 0;
}

.single-content hr {
    border: none;
    border-top: 1px solid var(--border-color);
    margin: 3rem 0;
}

/* Ghost Content Cards */
.single-content .kg-card {
    margin: 2rem 0;
}

.single-content .kg-image-card img,
.single-content .kg-image-card.kg-width-wide img,
.single-content .kg-image-card.kg-width-full img {
    width: 100%;
    height: auto;
    border-radius: 4px;
}

.single-content .kg-embed-card {
    margin: 2rem 0;
}

.single-content .kg-bookmark-card {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.5rem;
    background-color: var(--bg-secondary);
}

.single-content .kg-bookmark-container {
    text-decoration: none;
    color: inherit;
}

.single-content .kg-bookmark-title {
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.single-content .kg-bookmark-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.single-content .kg-bookmark-metadata {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 0.75rem;
}

.single-content .kg-callout-card {
    border-radius: 4px;
    padding: 1.5rem;
    margin: 2rem 0;
    border-left: 4px solid var(--accent-color);
    background-color: var(--bg-secondary);
}

.single-content .kg-callout-emoji {
    font-size: 1.5rem;
    margin-right: 0.75rem;
}

.single-content .kg-toggle-card {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    margin: 2rem 0;
    overflow: hidden;
}

.single-content .kg-toggle-heading {
    padding: 1rem 1.5rem;
    background-color: var(--bg-secondary);
    cursor: pointer;
    font-weight: 600;
    color: var(--text-primary);
}

.single-content .kg-toggle-content {
    padding: 1.5rem;
}

.single-content .kg-product-card {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.5rem;
    margin: 2rem 0;
    background-color: var(--bg-secondary);
}

.single-content .kg-button-card a {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s, border-color 0.2s;
}

.single-content .kg-button-card a:hover {
    background-color: var(--border-color);
    border-color: var(--accent-color);
}

.single-content .kg-gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.single-content .kg-gallery-image img {
    width: 100%;
    height: auto;
    border-radius: 4px;
}

/* Taxonomy Pages */
.taxonomy {
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

/* Pagination */
.gh-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 5rem;
    padding-top: 3rem;
    border-top: 1px solid var(--border-color);
}

.gh-pagination a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.gh-pagination a:hover {
    color: var(--link-hover);
}

.gh-pagination .page-number {
    display: none;
}

/* Footer */
.gh-foot {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0;
    margin-top: 6rem;
}

.gh-foot-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
}

.gh-copyright {
    color: var(--text-muted);
    font-size: 0.875rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.gh-copyright-main {
    margin-bottom: 0.25rem;
}

.gh-copyright-attribution {
    font-size: 0.8125rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.footer-emoji {
    width: 16px;
    height: 16px;
    vertical-align: middle;
    display: inline-block;
}

/* Hide Ghost Portal trigger button (floating green subscribe button) */
.gh-portal-triggerbtn-iframe,
.gh-portal-triggerbtn,
iframe[src*="portal-trigger"],
[data-portal-trigger] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Mobile Menu */
.gh-burger {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    width: 32px;
    height: 32px;
    position: relative;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.gh-burger span {
    display: block;
    width: 20px;
    height: 2px;
    background-color: currentColor;
    transition: all 0.3s;
}

.gh-burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.gh-burger.active span:nth-child(2) {
    opacity: 0;
}

.gh-burger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Responsive */
@media (max-width: 768px) {
    .gh-head-inner {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .gh-burger {
        display: flex;
    }

    .gh-head-menu {
        display: none;
        order: 3;
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        padding-top: 1rem;
        border-top: 1px solid var(--border-color);
    }

    .gh-head-menu.active {
        display: flex;
    }

    .gh-head-members {
        order: 2;
        width: 100%;
        justify-content: flex-start;
        padding-top: 1rem;
        border-top: 1px solid var(--border-color);
    }

    .gh-head-actions {
        width: 100%;
        justify-content: space-between;
    }

    .gh-canvas {
        padding: 0 1.5rem;
    }

    .single-title {
        font-size: 2rem;
    }

    .feed-title {
        font-size: 1.5rem;
    }

    .site-main {
        padding: 3rem 0;
    }

    .home-intro {
        margin-bottom: 3rem;
    }

    .intro-title h1 {
        font-size: 2.25rem;
    }

    .intro-tagline {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    .site-description {
        font-size: 1.125rem;
        margin-bottom: 2rem;
        text-align: center;
    }

    .home-intro {
        margin-bottom: 3rem;
    }

    .site-description {
        font-size: 1.125rem;
        margin-bottom: 2rem;
    }

    .subscribe-section {
        margin-bottom: 2rem;
    }

    .subscribe-form {
        flex-direction: column;
    }

    .subscribe-email {
        min-width: 100%;
    }

    .subscribe-button {
        width: 100%;
    }

    .feed-divider {
        margin: 4rem 0;
    }

    .post-feed {
        gap: 3rem;
    }

    /* Disable terminal animation on mobile for performance */
    .terminal-bg {
        display: none;
    }
}

