/* Info Products — Shared Stylesheet */

:root {
    --color-bg: #ffffff;
    --color-text: #1a1a2e;
    --color-text-muted: #555;
    --color-accent: #2563eb;
    --color-accent-hover: #1d4ed8;
    --color-surface: #f8f9fa;
    --color-border: #e5e7eb;
    --color-cta: #16a34a;
    --color-cta-hover: #15803d;
    --max-width: 720px;
    --max-width-wide: 960px;
}

[data-theme="dark"] {
    --color-bg: #0f172a;
    --color-text: #e2e8f0;
    --color-text-muted: #94a3b8;
    --color-accent: #60a5fa;
    --color-accent-hover: #93bbfd;
    --color-surface: #1e293b;
    --color-border: #334155;
    --color-cta: #22c55e;
    --color-cta-hover: #4ade80;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.7;
    font-size: 17px;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
.site-header {
    border-bottom: 1px solid var(--color-border);
    padding: 1rem 0;
}

.site-header .container {
    max-width: var(--max-width-wide);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--color-text);
    text-decoration: none;
}

.site-nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.site-nav a {
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.95rem;
}

.site-nav a:hover {
    color: var(--color-accent);
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.25rem;
    color: var(--color-text-muted);
}

/* Hero */
.hero {
    padding: 4rem 0 0;
    text-align: center;
}

.hero h1 {
    font-size: 2.4rem;
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--color-text-muted);
    max-width: 560px;
    margin: 0 auto 0;
}

.hero + .article-content {
    padding-top: 1.5rem;
}

.cta-button {
    display: inline-block;
    background: var(--color-cta);
    color: #fff;
    padding: 0.85rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.05rem;
    transition: background 0.2s;
}

.cta-button:hover {
    background: var(--color-cta-hover);
}

/* Article content */
.article-content {
    padding: 3rem 0;
}

.article-header {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-border);
}

.article-header h1 {
    font-size: 2.2rem;
    line-height: 1.25;
    margin-bottom: 0.75rem;
}

.article-header time {
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.article-content h2 {
    font-size: 1.5rem;
    margin: 2.5rem 0 1rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid var(--color-border);
}

.article-content h3 {
    font-size: 1.25rem;
    margin: 2rem 0 0.75rem;
}

.article-content p {
    margin-bottom: 1.25rem;
    line-height: 1.75;
}

.article-content ul, .article-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.article-content li {
    margin-bottom: 0.5rem;
    line-height: 1.7;
}

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

.article-content a:hover {
    color: var(--color-accent-hover);
}

.article-content blockquote {
    border-left: 3px solid var(--color-accent);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    background: var(--color-surface);
    border-radius: 0 6px 6px 0;
    font-style: italic;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.article-footer {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.article-footer a {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: background 0.2s;
}

.article-footer a:hover {
    background: var(--color-surface);
}

/* Blog index */
.blog-index {
    padding: 3rem 0;
}

.blog-index h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.blog-intro {
    color: var(--color-text-muted);
    margin-bottom: 2.5rem;
}

.post-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.post-card {
    padding: 1.5rem;
    background: var(--color-surface);
    border-radius: 8px;
    border: 1px solid var(--color-border);
}

.post-card h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.post-card h2 a {
    color: var(--color-text);
    text-decoration: none;
}

.post-card h2 a:hover {
    color: var(--color-accent);
}

.post-card p {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.post-card time {
    color: var(--color-text-muted);
    font-size: 0.85rem;
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 2rem 0;
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}
.footer-legal {
    margin-top: 0.75rem;
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}
.footer-legal a {
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.85rem;
}
.footer-legal a:hover {
    text-decoration: underline;
}

/* Nav Dropdown */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-muted);
    font-size: 0.95rem;
    font-family: inherit;
    padding: 0;
}

.nav-dropdown-toggle:hover {
    color: var(--color-accent);
}

.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 0.5rem 0;
    min-width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 100;
}

.nav-dropdown:hover .nav-dropdown-menu {
    display: block;
}

.nav-dropdown-menu a {
    display: block;
    padding: 0.5rem 1rem;
    color: var(--color-text);
    text-decoration: none;
    font-size: 0.9rem;
}

.nav-dropdown-menu a:hover {
    background: var(--color-surface);
    color: var(--color-accent);
}

/* Topic Navigation */
.topic-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-border);
}

.topic-nav-label {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    margin-right: 0.5rem;
}

.topic-link {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.topic-link:hover, .topic-link.active {
    background: var(--color-accent);
    color: #fff;
    border-color: var(--color-accent);
}

/* Blog CTA */
.blog-cta {
    margin: 3rem 0;
    padding: 2.5rem 2rem;
    background: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: 12px;
    text-align: center;
}

.blog-cta h3 {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
}

.blog-cta p {
    color: var(--color-text);
    margin-bottom: 1.5rem;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.article-content .blog-cta a.cta-button:not(.blog-cta-learn) {
    color: #fff;
    text-decoration: none;
}

.article-content .blog-cta a.cta-button:not(.blog-cta-learn):hover {
    color: #fff;
}

.blog-cta-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}
.blog-cta-buttons .blog-cta-free {
    background: #f2c94c;
    color: #000;
    border: 2px solid #f2c94c;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
}
.blog-cta-buttons .blog-cta-free:hover {
    background: #e6b93d;
    border-color: #e6b93d;
}
.blog-cta-buttons .blog-cta-learn {
    background: transparent;
    color: var(--color-text);
    border: 2px solid var(--color-text);
    text-decoration: none;
}
.blog-cta-buttons .blog-cta-learn:hover {
    background: var(--color-text);
    color: var(--color-bg);
}

/* Related Articles */
.related-articles {
    margin: 2.5rem 0;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
}

.related-articles h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    border-bottom: none;
    padding-bottom: 0;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

.article-content a.related-card {
    display: flex;
    flex-direction: column;
    padding: 1.25rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.article-content a.related-card:hover {
    border-color: var(--color-accent);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    color: inherit;
}

.related-title {
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    line-height: 1.35;
}

.related-desc {
    color: var(--color-text-muted);
    font-size: 0.85rem;
    line-height: 1.5;
}

/* Free Download Form */
.free-download {
    padding: 2.5rem 0;
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    text-align: center;
}

.free-download h2 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}

.free-download p {
    color: var(--color-text-muted);
    margin-bottom: 1.25rem;
}

.free-download-form {
    display: flex;
    gap: 0.75rem;
    max-width: 440px;
    margin: 0 auto;
    justify-content: center;
}

.free-download-form input[type="email"] {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--color-bg);
    color: var(--color-text);
}

.free-download-form input[type="email"]:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.cta-button-secondary {
    background: var(--color-accent) !important;
    white-space: nowrap;
    padding: 0.75rem 1.5rem !important;
}

.cta-button-secondary:hover {
    background: var(--color-accent-hover) !important;
}

.free-download-msg {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

/* Thank You / Download Page */
.thank-you-page {
    padding: 4rem 0;
    text-align: center;
    min-height: 50vh;
}

.thank-you-page h1 {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.thank-you-page .subtitle {
    color: var(--color-text-muted);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.download-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    max-width: 640px;
    margin: 0 auto 2rem;
    text-align: left;
}

.download-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    text-decoration: none;
    color: var(--color-text);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.download-card:hover {
    border-color: var(--color-cta);
    box-shadow: 0 2px 8px rgba(22, 163, 74, 0.1);
}

.download-card .icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.download-card .file-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.download-card .file-size {
    color: var(--color-text-muted);
    font-size: 0.8rem;
}

/* Free Download Success */
.free-success-page {
    padding: 4rem 0;
    text-align: center;
    min-height: 50vh;
}

.free-success-page h1 {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.free-success-page p {
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
}

/* Landing Blog Posts */
.landing-blog-posts {
    padding: 3rem 0;
    border-top: 1px solid var(--color-border);
}

.landing-blog-posts h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.landing-blog-posts .post-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.4rem;
}

.landing-blog-posts .post-card h3 a {
    color: var(--color-text);
    text-decoration: none;
}

.landing-blog-posts .post-card h3 a:hover {
    color: var(--color-accent);
}

/* Responsive */
@media (max-width: 640px) {
    .hero h1 { font-size: 1.8rem; }
    .article-header h1 { font-size: 1.6rem; }
    body { font-size: 16px; }
    .free-download-form {
        flex-direction: column;
    }
    .download-cards {
        grid-template-columns: 1fr;
    }
}

/* ============================
   Gumroad-Style Product Page
   ============================ */

/* Sticky top bar */
.product-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 900;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    transform: translateY(-100%);
    transition: transform 0.25s ease;
}
.product-topbar.visible {
    transform: translateY(0);
}
.product-topbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0.6rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.product-topbar-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}
.product-topbar-price {
    flex-shrink: 0;
    background: #f2c94c;
    color: #000;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 0.2rem 0.6rem;
    border-radius: 99px;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    transition: background 0.15s;
}
.product-topbar-price:hover {
    background: #e6b93d;
}
.product-topbar-title {
    font-weight: 600;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.product-topbar-cta {
    flex-shrink: 0;
    background: #f2c94c;
    color: #000;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 99px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s;
}
.product-topbar-cta:hover {
    background: #e6b93d;
}

/* Cover image area */
.gm-cover {
    border: 1px solid var(--color-border);
    border-bottom: none;
    max-width: 1100px;
    margin: 0 auto;
    background: #f4f4f0;
}
[data-theme="dark"] .gm-cover {
    background: #1e2430;
}
.gm-cover-inner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    min-height: 300px;
}
.gm-cover-inner img {
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
}

/* Two-column body */
.gm-body {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 340px;
    border: 1px solid var(--color-border);
    border-top: 1px solid var(--color-border);
}

/* Left column: main content */
.gm-main {
    padding: 1.75rem 2rem;
    border-right: 1px solid var(--color-border);
}

/* Title block */
.gm-title-block h1 {
    font-size: 1.75rem;
    line-height: 1.25;
    margin-bottom: 0.75rem;
}
.gm-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}
.gm-author-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-text-muted);
}

.gm-separator {
    height: 1px;
    background: var(--color-border);
    margin: 1.25rem 0;
}

/* Description content */
.gm-description h2 { font-size: 1.4rem; margin: 2rem 0 0.75rem; font-weight: 700; }
.gm-description h3 { font-size: 1.2rem; margin: 1.75rem 0 0.6rem; font-weight: 700; }
.gm-description p { margin-bottom: 1.1rem; line-height: 1.65; }
.gm-description ul, .gm-description ol { margin-bottom: 1.1rem; padding-left: 1.5rem; }
.gm-description li { margin-bottom: 0.35rem; line-height: 1.6; }
.gm-description strong { font-weight: 700; }
.gm-description em { font-style: italic; }
.gm-description hr { border: none; border-top: 1px solid var(--color-border); margin: 1.75rem 0; }
.gm-description a { color: var(--color-accent); text-decoration: underline; text-underline-offset: 2px; }

/* Right column: sidebar */
.gm-sidebar {
    padding: 1.5rem;
}
.gm-sidebar-sticky {
    position: sticky;
    top: 1.5rem;
}

/* Variant cards (stacked) */
.gm-variants {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 1rem;
}
.gm-variant-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 2px solid var(--color-border);
    background: var(--color-bg);
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.gm-variant-card:first-child {
    border-radius: 6px 6px 0 0;
}
.gm-variant-card:last-child {
    border-radius: 0 0 6px 6px;
    border-top: none;
}
.gm-variant-card.active {
    background: #1a1a2e;
    color: #fff;
    border-color: #1a1a2e;
}
[data-theme="dark"] .gm-variant-card {
    color: var(--color-text);
}
[data-theme="dark"] .gm-variant-card.active {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #e2e8f0;
}
.gm-variant-price {
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border: 2px solid currentColor;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}
.gm-variant-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
    min-width: 0;
}
.gm-variant-name {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
}
.gm-variant-desc {
    font-size: 0.78rem;
    font-weight: 400;
    line-height: 1.4;
    opacity: 0.75;
}

/* CTA button (Gumroad gold) */
.gm-cta {
    display: block;
    width: 100%;
    padding: 0.85rem 1.5rem;
    background: #f2c94c;
    color: #000;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s;
    margin-bottom: 1.25rem;
    text-align: center;
}
.gm-cta:hover {
    background: #e6b93d;
}

/* Feature cards in sidebar */
.gm-feature-list {
    display: flex;
    flex-direction: column;
}
.gm-feature-card {
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-bottom: none;
}
.gm-feature-card:first-child {
    border-radius: 6px 6px 0 0;
}
.gm-feature-card:last-child {
    border-bottom: 1px solid var(--color-border);
    border-radius: 0 0 6px 6px;
}
.gm-feature-card h4 {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}
.gm-feature-card p {
    font-size: 0.82rem;
    color: var(--color-text-muted);
    line-height: 1.5;
    margin: 0;
}

/* Content upgrade callout — injected mid-article */
.content-upgrade {
    margin: 2.5rem 0;
    padding: 1.75rem 1.5rem;
    background: var(--color-surface);
    border-left: 4px solid var(--color-accent, #f2c94c);
    border-radius: 0 12px 12px 0;
    text-align: left;
}
.content-upgrade-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent, #f2c94c);
    margin-bottom: 0.5rem;
}
.content-upgrade h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}
.content-upgrade p {
    color: var(--color-text-muted);
    margin-bottom: 1rem;
    line-height: 1.5;
}
.content-upgrade .content-upgrade-cta {
    cursor: pointer;
    font-family: inherit;
    border: none;
}

/* Email Modal */
.email-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}
.email-modal {
    background: var(--color-bg);
    border-radius: 12px;
    padding: 2rem;
    max-width: 400px;
    width: 90%;
    position: relative;
    text-align: center;
}
.email-modal-close {
    position: absolute;
    top: 0.75rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-text-muted);
}
.email-modal h3 {
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}
.email-modal p {
    color: var(--color-text-muted);
    margin-bottom: 1.25rem;
}
.email-modal-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.email-modal-form input[type="email"] {
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--color-bg);
    color: var(--color-text);
}
.email-modal-form input[type="email"]:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}
.email-modal-msg {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

/* Checkout Modal (Stripe Embedded Checkout) */
.checkout-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
}
.checkout-modal {
    background: var(--color-bg);
    border-radius: 12px;
    max-width: 500px;
    width: 95%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}
.checkout-modal-close {
    position: absolute;
    top: 0.5rem;
    right: 0.75rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-text-muted);
    z-index: 10;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.checkout-modal-close:hover {
    color: var(--color-text);
}
.checkout-loading {
    padding: 3rem 2rem;
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.95rem;
}
.checkout-modal-msg {
    padding: 1rem 2rem 1.5rem;
    text-align: center;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

/* Product Preview Grid */
.gm-preview {
    margin-bottom: 1.5rem;
}
.gm-preview-label {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.gm-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}
.gm-preview-grid img {
    width: 100%;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
}
.gm-preview-grid img:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

/* Lightbox */
.gm-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0,0,0,0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.gm-lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

/* Responsive — Gumroad Product Page */
@media (max-width: 768px) {
    .gm-body {
        grid-template-columns: 1fr;
    }
    .gm-main {
        border-right: none;
        border-bottom: 1px solid var(--color-border);
        padding: 1.25rem 1rem;
    }
    .gm-sidebar {
        padding: 1.25rem 1rem;
    }
    .gm-sidebar-sticky {
        position: static;
    }
    .gm-cover-inner {
        padding: 1rem;
        min-height: 200px;
    }
    .gm-title-block h1 {
        font-size: 1.4rem;
    }
    .product-topbar-title {
        display: none;
    }
    .article-header h1 {
        font-size: 1.6rem;
    }
    .article-content h2 {
        font-size: 1.3rem;
    }
    .blog-cta {
        padding: 1.75rem 1.25rem;
    }
    .related-grid {
        grid-template-columns: 1fr;
    }
    .gm-preview-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================
   Interactive Tool Pages
   ============================ */

.tool-hero {
    padding: 3.5rem 0 2rem;
    text-align: center;
}
.tool-hero h1 {
    font-size: 2.2rem;
    line-height: 1.2;
    margin-bottom: 0.75rem;
    letter-spacing: -0.02em;
}
.tool-subtitle {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    max-width: 560px;
    margin: 0 auto;
}

.tool-section {
    padding: 0 0 2rem;
}
.tool-container {
    max-width: var(--max-width-wide);
}

/* Form elements */
.tool-form {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 2rem;
}
.tool-form h2 {
    font-size: 1.3rem;
    margin-bottom: 1.25rem;
}
.tool-field-group {
    margin-bottom: 1.5rem;
}
.tool-field-group label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}
.tool-field-group .tool-hint {
    display: block;
    font-size: 0.8rem;
    color: var(--color-text-muted);
    margin-bottom: 0.4rem;
}
.tool-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.tool-input, .tool-select {
    width: 100%;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--color-bg);
    color: var(--color-text);
}
.tool-input:focus, .tool-select:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.tool-calculate-btn {
    display: block;
    width: 100%;
    padding: 0.85rem 1.5rem;
    background: var(--color-cta);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.2s;
    margin-top: 0.5rem;
}
.tool-calculate-btn:hover {
    background: var(--color-cta-hover);
}

/* Results */
.tool-results {
    margin-top: 2rem;
}
.tool-results h2 {
    font-size: 1.4rem;
    margin-bottom: 1.25rem;
}
.tool-result-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.25rem;
}
.tool-result-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}
.tool-result-highlight {
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-cta);
    margin-bottom: 0.5rem;
    font-variant-numeric: tabular-nums;
}
.tool-result-label {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Breakdown tables */
.tool-breakdown-table {
    width: 100%;
    border-collapse: collapse;
    font-variant-numeric: tabular-nums;
    margin-top: 0.75rem;
}
.tool-breakdown-table th,
.tool-breakdown-table td {
    padding: 0.6rem 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
    font-size: 0.92rem;
}
.tool-breakdown-table th {
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.tool-breakdown-table td:last-child,
.tool-breakdown-table th:last-child {
    text-align: right;
}
.tool-breakdown-table tr.tool-row-total {
    font-weight: 700;
    border-top: 2px solid var(--color-text);
}
.tool-breakdown-table tr.tool-row-total td {
    border-bottom: none;
    padding-top: 0.85rem;
}

/* Comparison columns (mortgage) */
.tool-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}
.tool-comparison-col {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
}
.tool-comparison-col h3 {
    font-size: 1.05rem;
    margin-bottom: 1rem;
}
.tool-winner-badge {
    display: inline-block;
    background: var(--color-cta);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.6rem;
    border-radius: 99px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-left: 0.5rem;
    vertical-align: middle;
}

/* Severity badges (inspection) */
.tool-badge-green {
    display: inline-block;
    background: #dcfce7;
    color: #166534;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.3rem 0.85rem;
    border-radius: 99px;
}
.tool-badge-yellow {
    display: inline-block;
    background: #fef9c3;
    color: #854d0e;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.3rem 0.85rem;
    border-radius: 99px;
}
.tool-badge-red {
    display: inline-block;
    background: #fee2e2;
    color: #991b1b;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.3rem 0.85rem;
    border-radius: 99px;
}
[data-theme="dark"] .tool-badge-green {
    background: #14532d;
    color: #86efac;
}
[data-theme="dark"] .tool-badge-yellow {
    background: #713f12;
    color: #fde047;
}
[data-theme="dark"] .tool-badge-red {
    background: #7f1d1d;
    color: #fca5a5;
}

/* CTA section */
.tool-cta-section {
    padding: 2.5rem 0;
}
.tool-cta-card {
    background: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: 12px;
    padding: 2.5rem 2rem;
    text-align: center;
    max-width: var(--max-width);
    margin: 0 auto;
}
.tool-cta-card h2 {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
}
.tool-cta-card p {
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Email capture section */
.tool-email-section {
    padding: 2.5rem 0;
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    text-align: center;
}
.tool-email-section h2 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}
.tool-email-section p {
    color: var(--color-text-muted);
    margin-bottom: 1.25rem;
}
.tool-email-form {
    display: flex;
    gap: 0.75rem;
    max-width: 440px;
    margin: 0 auto;
    justify-content: center;
}
.tool-email-form input[type="email"] {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--color-bg);
    color: var(--color-text);
}
.tool-email-form input[type="email"]:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.tool-email-msg {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

/* SEO content below tool */
.tool-seo-content {
    padding: 2.5rem 0;
    border-top: 1px solid var(--color-border);
}
.tool-seo-content .article-content h2:first-child {
    margin-top: 0;
}

/* Disclaimer */
.tool-disclaimer {
    padding: 0.75rem 0;
}
.tool-disclaimer p {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-align: center;
    max-width: var(--max-width);
    margin: 0 auto;
}

/* Checkbox list (inspection) */
.tool-checkbox-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.tool-checkbox-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--color-border);
}
.tool-checkbox-list li:last-child {
    border-bottom: none;
}
.tool-checkbox-list input[type="checkbox"] {
    margin-top: 0.25rem;
    flex-shrink: 0;
    width: 1.1rem;
    height: 1.1rem;
    accent-color: var(--color-accent);
}
.tool-checkbox-label {
    font-size: 0.92rem;
    line-height: 1.4;
}
.tool-checkbox-detail {
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

/* Responsive — Tool Pages */
@media (max-width: 640px) {
    .tool-hero h1 { font-size: 1.7rem; }
    .tool-subtitle { font-size: 1rem; }
    .tool-form { padding: 1.25rem; }
    .tool-field-row { grid-template-columns: 1fr; }
    .tool-comparison { grid-template-columns: 1fr; }
    .tool-email-form { flex-direction: column; }
    .tool-result-highlight { font-size: 1.6rem; }
    .tool-cta-card { padding: 1.75rem 1.25rem; }
}

/* ============================
   Mystery Offer Banner
   ============================ */

.mystery-offer-banner {
    position: sticky;
    top: 0;
    z-index: 950;
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    color: #fff;
    text-align: center;
    padding: 0.75rem 1rem;
}
.mystery-offer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}
.mystery-offer-text {
    font-size: 1.05rem;
}
.mystery-offer-text strong {
    font-size: 1.3rem;
}
.mystery-timer {
    font-size: 1.3rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    background: rgba(0,0,0,0.2);
    padding: 0.3rem 0.75rem;
    border-radius: 6px;
    letter-spacing: 0.05em;
}

/* Discounted price display — breaks out of the 40px circle into a stacked layout */
.gm-variant-price.mystery-active {
    width: auto;
    min-width: 50px;
    height: auto;
    border: none;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    font-size: 0.85rem;
    font-weight: 700;
    color: #7c3aed;
}
.gm-variant-price.mystery-active .gm-variant-original {
    font-size: 0.7rem;
    font-weight: 400;
    text-decoration: line-through;
    opacity: 0.5;
    line-height: 1;
}
.gm-variant-price.mystery-active .gm-variant-discounted {
    font-size: 0.85rem;
    font-weight: 700;
    line-height: 1.2;
}
[data-theme="dark"] .gm-variant-price.mystery-active {
    color: #c084fc;
}
.gm-variant-card.active .gm-variant-price.mystery-active {
    color: #c084fc;
}
[data-theme="dark"] .gm-variant-card.active .gm-variant-price.mystery-active {
    color: #7c3aed;
}

/* ─── Bundle page ─────────────────────────────────────────────────────────── */

.bundle-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.bundle-hero {
    text-align: center;
    padding: 2.5rem 0 1.5rem;
}

.bundle-hero h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.bundle-subtitle {
    font-size: 1.15rem;
    color: #555;
    max-width: 600px;
    margin: 0 auto;
}

.bundle-body {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 2.5rem;
    align-items: start;
    margin-bottom: 3rem;
}

.bundle-main {
    min-width: 0;
}

.bundle-description {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #333;
    margin-bottom: 2rem;
}

.bundle-description h2 {
    font-size: 1.4rem;
    margin: 1.8rem 0 0.8rem;
}

.bundle-products-section h2 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.bundle-product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.bundle-product-card {
    border: 1px solid #e5e5e5;
    border-radius: 10px;
    padding: 1.2rem;
    background: #fafafa;
    transition: border-color 0.2s;
}

.bundle-product-card:hover {
    border-color: #16a34a;
}

.bundle-product-card h3 {
    font-size: 1rem;
    margin: 0 0 0.4rem;
}

.bundle-product-desc {
    font-size: 0.85rem;
    color: #555;
    margin: 0 0 0.5rem;
    line-height: 1.4;
}

.bundle-product-value {
    font-size: 0.85rem;
    color: #888;
    margin: 0 0 0.4rem;
}

.bundle-product-link {
    font-size: 0.85rem;
    color: #16a34a;
    text-decoration: none;
}

.bundle-product-link:hover {
    text-decoration: underline;
}

/* Sidebar */
.bundle-sidebar-sticky {
    position: sticky;
    top: 2rem;
}

.bundle-pricing-card {
    border: 2px solid #16a34a;
    border-radius: 12px;
    overflow: hidden;
}

.bundle-pricing-header {
    background: #16a34a;
    color: #fff;
    text-align: center;
    padding: 0.75rem;
    font-weight: 700;
    font-size: 1rem;
}

.bundle-pricing-body {
    padding: 1.5rem;
    text-align: center;
}

.bundle-price-compare {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.bundle-individual-total {
    font-size: 1.1rem;
    color: #999;
    text-decoration: line-through;
}

.bundle-arrow {
    color: #999;
    font-size: 1.2rem;
}

.bundle-price {
    font-size: 1.8rem;
    font-weight: 800;
    color: #16a34a;
}

.bundle-savings {
    font-size: 0.9rem;
    color: #16a34a;
    font-weight: 600;
    margin: 0;
}

.bundle-upgrade-pricing {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e5e5;
    text-align: left;
}

.bundle-credit-line {
    font-size: 0.9rem;
    color: #555;
    margin: 0 0 0.3rem;
}

.bundle-upgrade-line {
    font-size: 1.05rem;
    color: #16a34a;
    margin: 0;
}

.bundle-cta {
    display: block;
    width: 100%;
    padding: 0.9rem;
    background: #16a34a;
    color: #fff;
    border: none;
    border-radius: 0 0 10px 10px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.bundle-cta:hover {
    background: #15803d;
}

.bundle-guarantee {
    text-align: center;
    font-size: 0.8rem;
    color: #888;
    margin-top: 0.75rem;
}

/* Upgrade banner */
.bundle-upgrade-banner {
    background: #16a34a;
    color: #fff;
    padding: 0.75rem 1.5rem;
    text-align: center;
    font-size: 0.95rem;
}

.bundle-upgrade-inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.bundle-upgrade-timer {
    font-weight: 700;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Mobile responsive — bundle */
@media (max-width: 768px) {
    .bundle-body {
        grid-template-columns: 1fr;
    }

    .bundle-product-grid {
        grid-template-columns: 1fr;
    }

    .bundle-sidebar-sticky {
        position: static;
    }

    .bundle-hero h1 {
        font-size: 1.6rem;
    }
}

@media (max-width: 640px) {
    .mystery-offer-text { font-size: 0.9rem; }
    .mystery-offer-text strong { font-size: 1.1rem; }
    .mystery-timer { font-size: 1.1rem; }
}
