/* ===========================================================================
   Rumi — Ghost theme stylesheet
   Author: Rashedul Haque Rumi
   Modern SaaS-style personal brand theme · Light + Dark mode · Poppins
   ===========================================================================
   Table of contents
   1.  Design tokens (CSS variables) + theming
   2.  Reset & base
   3.  Layout helpers (container, grid, section)
   4.  Buttons & links
   5.  Header / navigation
   6.  Hero
   7.  Sections (intro, projects, services, timeline, tech, contact CTA)
   8.  Cards (post, project, service)
   9.  Blog / archive / pagination
   10. Single post & pages
   11. Author & error pages
   12. Forms (newsletter, contact)
   13. Footer
   14. Utilities & animations
   15. Responsive breakpoints
   ========================================================================= */

/* ---------------------------------------------------------------------------
   1. Design tokens + theming
   ------------------------------------------------------------------------- */
:root {
    /* Brand colors */
    --indigo:        #6d28d9;
    --indigo-600:    #7c3aed;
    --indigo-500:    #8b5cf6;
    --cyan:          #06b6d4;
    --blue:          #3b82f6;

    /* Gradients (used sparingly) */
    --gradient-brand: linear-gradient(135deg, #7c3aed 0%, #6366f1 45%, #06b6d4 100%);
    --gradient-soft:  linear-gradient(135deg, rgba(124,58,237,.12), rgba(6,182,212,.12));

    /* Radii & shadows */
    --radius-sm: 10px;
    --radius:    16px;
    --radius-lg: 24px;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
    --shadow:    0 8px 24px rgba(15, 23, 42, .08);
    --shadow-lg: 0 24px 60px rgba(15, 23, 42, .14);

    /* Typography
       --gh-font-heading / --gh-font-body are populated by Ghost's custom font
       settings (Design → Brand). We fall back to Poppins when unset. */
    --font-sans: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --gh-font-heading: var(--font-sans);
    --gh-font-body: var(--font-sans);

    /* Spacing / layout */
    --container: 1180px;
    --container-narrow: 760px;
    --header-h: 72px;

    --transition: 220ms cubic-bezier(.4, 0, .2, 1);
}

/* Light theme (default) */
:root,
[data-theme="light"] {
    --bg:        #ffffff;
    --bg-soft:   #f6f7fb;
    --bg-alt:    #f1f3fa;
    --surface:   #ffffff;
    --surface-2: #ffffff;
    --border:    #e6e8f0;
    --text:      #0f172a;
    --text-soft: #475569;
    --text-mute: #94a3b8;
    --primary:   var(--indigo);
    --primary-contrast: #ffffff;
    --accent:    var(--cyan);
    --hero-glow: radial-gradient(60% 60% at 50% 0%, rgba(124,58,237,.18), transparent 70%);
}

/* Dark theme — dark navy background */
[data-theme="dark"] {
    --bg:        #0b1020;
    --bg-soft:   #0f1630;
    --bg-alt:    #111933;
    --surface:   #131b36;
    --surface-2: #182142;
    --border:    #25305a;
    --text:      #eef1fb;
    --text-soft: #b6bed8;
    --text-mute: #7f8ab4;
    --primary:   #8b5cf6;
    --primary-contrast: #ffffff;
    --accent:    #22d3ee;
    --hero-glow: radial-gradient(60% 60% at 50% 0%, rgba(124,58,237,.28), transparent 70%);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
    --shadow:    0 10px 30px rgba(0, 0, 0, .45);
    --shadow-lg: 0 28px 70px rgba(0, 0, 0, .55);
}

/* ---------------------------------------------------------------------------
   2. Reset & base
   ------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--gh-font-body, var(--font-sans));
    font-size: 17px;
    line-height: 1.7;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background var(--transition), color var(--transition);
}

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

h1, h2, h3, h4 {
    font-family: var(--gh-font-heading, var(--font-sans));
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 .5em;
    letter-spacing: -.02em;
}

p { margin: 0 0 1em; }

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition), opacity var(--transition);
}
a:hover { color: var(--accent); }

ul, ol { margin: 0; padding: 0; }

code {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    background: var(--bg-alt);
    padding: .15em .4em;
    border-radius: 6px;
    font-size: .9em;
}

::selection { background: rgba(124, 58, 237, .25); }

.site-wrapper { display: flex; flex-direction: column; min-height: 100vh; }
.site-main { flex: 1 0 auto; }

/* ---------------------------------------------------------------------------
   3. Layout helpers
   ------------------------------------------------------------------------- */
.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}
.container-narrow {
    width: 100%;
    max-width: var(--container-narrow);
    margin: 0 auto;
    padding: 0 24px;
}

.section { padding: 88px 0; }
.section-alt { background: var(--bg-soft); }

.section-head { text-align: center; max-width: 640px; margin: 0 auto 48px; }
.section-eyebrow {
    display: inline-block;
    font-size: .8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--primary);
    margin-bottom: 12px;
}
.section-title { font-size: clamp(1.6rem, 3vw, 2.4rem); }
.section-lead { color: var(--text-soft); font-size: 1.05rem; }
.section-foot { text-align: center; margin-top: 44px; }

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.gradient-text {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.empty-state { text-align: center; color: var(--text-mute); padding: 48px 0; }

/* ---------------------------------------------------------------------------
   4. Buttons & links
   ------------------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: inherit;
    font-size: .95rem;
    font-weight: 600;
    line-height: 1;
    padding: 12px 22px;
    border-radius: 999px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition), background var(--transition), border-color var(--transition);
    white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-lg { padding: 15px 30px; font-size: 1rem; }
.btn-block { display: flex; width: 100%; }

.btn-primary {
    background: var(--gradient-brand);
    color: #fff;
    box-shadow: 0 8px 24px rgba(124, 58, 237, .35);
}
.btn-primary:hover { color: #fff; box-shadow: 0 12px 30px rgba(124, 58, 237, .45); }

.btn-secondary {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
}
.btn-secondary:hover { color: var(--text); border-color: var(--primary); }

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}
.link-arrow svg { transition: transform var(--transition); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------------------------------------------------------------------------
   5. Header / navigation
   ------------------------------------------------------------------------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: color-mix(in srgb, var(--bg) 80%, transparent);
    backdrop-filter: saturate(180%) blur(14px);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color var(--transition), background var(--transition);
}
.site-header.is-scrolled { border-bottom-color: var(--border); box-shadow: var(--shadow-sm); }

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-h);
    gap: 20px;
}

.nav-brand { display: inline-flex; align-items: center; }
.nav-brand-text { font-weight: 700; font-size: 1.2rem; color: var(--text); letter-spacing: -.02em; }
.nav-logo { max-height: 36px; width: auto; }

.nav-menu { margin-left: auto; }
.nav-list { display: flex; align-items: center; gap: 4px; list-style: none; }
.nav-item a {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 10px;
    color: var(--text-soft);
    font-weight: 500;
    font-size: .95rem;
}
.nav-item a:hover { color: var(--text); background: var(--bg-alt); }
.nav-item--active a { color: var(--primary); }

.nav-actions { display: flex; align-items: center; gap: 10px; }

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px; height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.theme-toggle:hover { transform: translateY(-2px); border-color: var(--primary); }
.theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

.nav-burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px; height: 42px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    cursor: pointer;
}
.nav-burger span {
    display: block;
    width: 18px; height: 2px;
    margin: 0 auto;
    background: var(--text);
    border-radius: 2px;
    transition: transform var(--transition), opacity var(--transition);
}
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------------------------------------------------------------------------
   6. Hero
   ------------------------------------------------------------------------- */
.hero { position: relative; padding: clamp(64px, 10vw, 120px) 0; overflow: hidden; }
.hero-bg {
    position: absolute;
    inset: 0;
    background: var(--hero-glow);
    pointer-events: none;
}
.hero-inner { position: relative; max-width: 880px; margin: 0 auto; text-align: center; }
.hero-eyebrow {
    display: inline-block;
    font-size: .85rem;
    font-weight: 500;
    color: var(--text-soft);
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 8px 16px;
    border-radius: 999px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}
.hero-title { font-size: clamp(2rem, 5.2vw, 3.6rem); font-weight: 800; margin-bottom: 20px; }
.hero-sub { font-size: clamp(1rem, 2vw, 1.2rem); color: var(--text-soft); max-width: 680px; margin: 0 auto 32px; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 48px;
    list-style: none;
    margin-top: 56px;
    flex-wrap: wrap;
}
.hero-stats li { text-align: center; }
.hero-stats strong { display: block; font-size: 2rem; font-weight: 800; }
.hero-stats span { color: var(--text-mute); font-size: .9rem; }

/* ---------------------------------------------------------------------------
   7. Sections
   ------------------------------------------------------------------------- */
/* Intro */
.intro-inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: center; }
.intro-text p { color: var(--text-soft); }
.intro-roles { display: flex; flex-wrap: wrap; gap: 12px; align-content: center; }
.role-chip {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 10px 18px;
    font-weight: 500;
    font-size: .92rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), border-color var(--transition);
}
.role-chip:hover { transform: translateY(-3px); border-color: var(--primary); }

/* Timeline */
.timeline { list-style: none; max-width: 720px; margin: 0 auto; position: relative; padding-left: 28px; }
.timeline::before {
    content: "";
    position: absolute;
    left: 7px; top: 6px; bottom: 6px;
    width: 2px;
    background: linear-gradient(var(--primary), var(--accent));
    opacity: .35;
}
.timeline-item { position: relative; padding: 0 0 32px 24px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-dot {
    position: absolute;
    left: -28px; top: 4px;
    width: 16px; height: 16px;
    border-radius: 50%;
    background: var(--gradient-brand);
    box-shadow: 0 0 0 4px var(--bg);
}
.timeline-role { display: block; font-weight: 600; font-size: 1.05rem; margin-bottom: 4px; }
.timeline-content p { color: var(--text-soft); margin: 0; }

/* Tech grid */
.tech-grid { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; max-width: 820px; margin: 0 auto; }
.tech-pill {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px 18px;
    font-weight: 500;
    font-size: .92rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), border-color var(--transition), color var(--transition);
}
.tech-pill:hover { transform: translateY(-3px); border-color: var(--accent); color: var(--accent); }

/* Process */
.process-step {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow-sm);
}
.process-num {
    display: inline-block;
    font-size: 1.6rem;
    font-weight: 800;
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 8px;
}
.process-step h3 { font-size: 1.1rem; margin-bottom: 6px; }
.process-step p { color: var(--text-soft); margin: 0; font-size: .95rem; }

/* Contact CTA */
.contact-cta {
    position: relative;
    text-align: center;
    background: var(--gradient-brand);
    color: #fff;
    border-radius: var(--radius-lg);
    padding: clamp(40px, 6vw, 72px) 32px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}
.contact-cta-glow {
    position: absolute;
    inset: 0;
    background: radial-gradient(40% 60% at 80% 10%, rgba(255,255,255,.25), transparent 60%);
    pointer-events: none;
}
.contact-cta-title { position: relative; color: #fff; font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
.contact-cta-sub { position: relative; color: rgba(255,255,255,.9); margin-bottom: 28px; }
.contact-cta .btn-secondary { background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.35); }
.contact-cta .btn-secondary:hover { background: rgba(255,255,255,.24); }

/* ---------------------------------------------------------------------------
   8. Cards
   ------------------------------------------------------------------------- */
.post-card,
.project-card,
.service-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
    overflow: hidden;
}
.post-card:hover,
.project-card:hover,
.service-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: color-mix(in srgb, var(--primary) 40%, var(--border));
}

/* Post card */
.post-card { display: flex; flex-direction: column; }
.post-card-image-link { display: block; aspect-ratio: 16 / 10; overflow: hidden; }
.post-card-image { width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition); }
.post-card:hover .post-card-image { transform: scale(1.05); }
.post-card-image--placeholder {
    display: flex; align-items: center; justify-content: center;
    background: var(--gradient-soft);
    color: var(--primary);
    font-weight: 700;
    font-size: 1.1rem;
}
.post-card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.post-card-tag {
    align-self: flex-start;
    font-size: .75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--primary);
    margin-bottom: 10px;
}
.post-card-title { font-size: 1.2rem; margin-bottom: 10px; }
.post-card-title a { color: var(--text); }
.post-card-title a:hover { color: var(--primary); }
.post-card-excerpt { color: var(--text-soft); font-size: .95rem; flex: 1; }
.post-card-meta {
    display: flex; align-items: center; gap: 10px;
    font-size: .82rem; color: var(--text-mute);
    margin-top: 16px; flex-wrap: wrap;
}
.post-card-meta > *::after { content: "·"; margin-left: 10px; color: var(--text-mute); }
.post-card-meta > *:last-child::after { content: ""; margin: 0; }

/* Project card */
.project-card { padding: 26px; display: flex; flex-direction: column; }
.project-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.project-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 52px; height: 52px;
    border-radius: 14px;
    background: var(--gradient-soft);
    font-size: 1.5rem;
}
.project-badge {
    font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em;
    color: var(--primary);
    background: color-mix(in srgb, var(--primary) 12%, transparent);
    padding: 5px 12px; border-radius: 999px;
}
.project-name { font-size: 1.25rem; margin-bottom: 8px; }
.project-desc { color: var(--text-soft); font-size: .95rem; flex: 1; margin-bottom: 16px; }
.project-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: .92rem; }
.project-link svg { transition: transform var(--transition); }
.project-link:hover svg { transform: translate(3px, -3px); }

/* Service card */
.service-card { padding: 30px; }
.service-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 56px; height: 56px;
    border-radius: 16px;
    background: var(--gradient-soft);
    font-size: 1.6rem;
    margin-bottom: 18px;
}
.service-title { font-size: 1.2rem; margin-bottom: 8px; }
.service-desc { color: var(--text-soft); font-size: .95rem; margin: 0; }

/* ---------------------------------------------------------------------------
   9. Blog / archive / pagination
   ------------------------------------------------------------------------- */
.page-hero { padding: 72px 0 24px; text-align: center; }
.page-hero-title { font-size: clamp(1.9rem, 4vw, 3rem); }
.page-hero-sub { color: var(--text-soft); font-size: 1.1rem; max-width: 620px; margin: 0 auto; }

.pagination {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; margin-top: 56px;
}
.pagination-btn {
    padding: 11px 20px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font-weight: 600;
    font-size: .9rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), border-color var(--transition);
}
.pagination-btn:hover { transform: translateY(-2px); border-color: var(--primary); color: var(--text); }
.pagination-btn.is-disabled { opacity: .4; pointer-events: none; }
.pagination-info { color: var(--text-mute); font-size: .9rem; }

/* ---------------------------------------------------------------------------
   10. Single post & pages
   ------------------------------------------------------------------------- */
.post-header { text-align: center; padding: 56px 24px 32px; }
.post-tag {
    display: inline-block; font-size: .8rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .08em; color: var(--primary); margin-bottom: 16px;
}
.post-title { font-size: clamp(1.9rem, 4.5vw, 3rem); }
.post-subtitle { color: var(--text-soft); font-size: 1.2rem; max-width: 640px; margin: 0 auto 24px; }
.post-meta {
    display: flex; align-items: center; justify-content: center; gap: 14px;
    color: var(--text-mute); font-size: .9rem; flex-wrap: wrap;
}
.post-meta-author { display: inline-flex; align-items: center; gap: 8px; }
.post-meta-avatar { border-radius: 50%; }
.post-meta a { color: var(--text-soft); font-weight: 500; }
.post-meta > *::after { content: "·"; margin-left: 14px; }
.post-meta > *:last-child::after { content: ""; margin: 0; }

.post-feature-image { margin: 0 auto 40px; max-width: var(--container); }
.post-feature-image img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.post-feature-image figcaption { text-align: center; color: var(--text-mute); font-size: .85rem; margin-top: 10px; }

/* Content typography */
.gh-content { font-size: 1.08rem; }
.gh-content > * { margin-bottom: 1.4em; }
.gh-content h2 { font-size: 1.7rem; margin-top: 1.6em; }
.gh-content h3 { font-size: 1.35rem; margin-top: 1.4em; }
.gh-content a { text-decoration: underline; text-underline-offset: 3px; }
.gh-content img,
.gh-content .kg-card { border-radius: var(--radius); }

/* Koenig editor card widths — let "wide" and "full" cards break out of the
   narrow reading column. Required by Ghost / gscan. */
.gh-content .kg-width-wide {
    position: relative;
    width: 75vw;
    min-width: 100%;
    margin-left: 50%;
    transform: translateX(-50%);
    max-width: 1100px;
}
.gh-content .kg-width-full {
    position: relative;
    width: 100vw;
    margin-left: 50%;
    transform: translateX(-50%);
    border-radius: 0;
    max-width: none;
}
.gh-content .kg-width-full img { border-radius: 0; width: 100%; }
.gh-content blockquote {
    margin: 1.6em 0;
    padding: 4px 24px;
    border-left: 4px solid var(--primary);
    color: var(--text-soft);
    font-style: italic;
}
.gh-content pre {
    background: #0b1020;
    color: #e2e8f0;
    padding: 20px;
    border-radius: var(--radius);
    overflow-x: auto;
}
.gh-content pre code { background: none; padding: 0; }
.gh-content figcaption { text-align: center; color: var(--text-mute); font-size: .85rem; }
.gh-content ul, .gh-content ol { padding-left: 1.4em; }
.gh-content li { margin-bottom: .5em; }

/* Post footer */
.post-footer { padding-top: 32px; margin-top: 40px; border-top: 1px solid var(--border); }
.post-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.tag-pill {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 7px 14px;
    font-size: .85rem;
    color: var(--text-soft);
}
.tag-pill:hover { border-color: var(--primary); color: var(--primary); }

.author-bio { display: flex; gap: 18px; align-items: flex-start; background: var(--bg-soft); padding: 24px; border-radius: var(--radius); }
.author-bio-avatar { border-radius: 50%; flex-shrink: 0; }
.author-bio-name { font-size: 1.15rem; margin-bottom: 4px; }
.author-bio-name a { color: var(--text); }
.author-bio-text p { color: var(--text-soft); margin: 0; font-size: .95rem; }

.post-subscribe { margin: 56px auto; }
.post-subscribe-card {
    text-align: center;
    background: var(--gradient-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px 28px;
}
.post-subscribe-card h3 { font-size: 1.4rem; }
.post-subscribe-card p { color: var(--text-soft); }

/* Generic pages */
.page-feature-image { margin: 24px auto 40px; }
.page-feature-image img { border-radius: var(--radius-lg); box-shadow: var(--shadow); }

/* About */
.about-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 48px; align-items: start; }
.about-main p { color: var(--text-soft); }
.about-subhead { margin-top: 32px; font-size: 1.3rem; }
.checklist { list-style: none; }
.checklist li { position: relative; padding-left: 30px; margin-bottom: 12px; color: var(--text-soft); }
.checklist li::before {
    content: "✓";
    position: absolute; left: 0; top: 0;
    width: 20px; height: 20px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--gradient-brand);
    color: #fff; border-radius: 50%; font-size: .7rem; font-weight: 700;
}
.about-side { position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 20px; }
.about-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm); }
.about-card h3 { font-size: 1.1rem; margin-bottom: 14px; }
.about-facts { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; }
.about-facts dt { color: var(--text-mute); font-size: .85rem; }
.about-facts dd { margin: 0; font-weight: 500; font-size: .9rem; }

/* ---------------------------------------------------------------------------
   11. Author & error pages
   ------------------------------------------------------------------------- */
.author-hero { padding: 64px 0 24px; }
.author-hero-inner { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.author-hero-avatar { border-radius: 50%; border: 3px solid var(--surface); box-shadow: var(--shadow); }
.author-hero-meta { display: flex; gap: 18px; flex-wrap: wrap; color: var(--text-mute); font-size: .9rem; margin-top: 12px; }

.error-page { display: flex; align-items: center; justify-content: center; min-height: 70vh; text-align: center; }
.error-code { font-size: clamp(5rem, 18vw, 11rem); font-weight: 800; line-height: 1; }
.error-title { font-size: clamp(1.4rem, 3vw, 2rem); }
.error-sub { color: var(--text-soft); max-width: 460px; margin: 0 auto 28px; }
.error-stack { background: var(--bg-alt); padding: 20px; border-radius: var(--radius); overflow-x: auto; font-size: .8rem; margin-top: 40px; }

/* ---------------------------------------------------------------------------
   12. Forms
   ------------------------------------------------------------------------- */
.signup-form { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; align-items: center; }
.signup-input {
    flex: 1 1 260px;
    min-width: 0;
    padding: 13px 18px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font-family: inherit;
    font-size: .95rem;
}
.signup-input:focus { outline: 2px solid var(--primary); outline-offset: 1px; }
.signup-message { flex-basis: 100%; text-align: center; font-size: .85rem; color: var(--text-mute); }

/* Footer newsletter card */
.footer-cta { padding: 40px 0; }
.footer-cta-card {
    display: flex; align-items: center; justify-content: space-between; gap: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow);
    flex-wrap: wrap;
}
.footer-cta-title { font-size: 1.6rem; margin-bottom: 6px; }
.footer-cta-sub { color: var(--text-soft); margin: 0; max-width: 420px; }
.footer-cta .signup-form { justify-content: flex-end; flex: 1 1 320px; }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px; align-items: start; }
.contact-info p { color: var(--text-soft); }
.contact-list { list-style: none; margin: 28px 0; display: flex; flex-direction: column; gap: 20px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-list-icon {
    width: 44px; height: 44px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--gradient-soft); border-radius: 12px; font-size: 1.2rem;
}
.contact-socials { display: flex; gap: 16px; flex-wrap: wrap; }
.contact-form-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow); }
.form-row { margin-bottom: 18px; display: flex; flex-direction: column; gap: 6px; }
.form-row label { font-weight: 500; font-size: .9rem; }
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 13px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text);
    font-family: inherit;
    font-size: .95rem;
    resize: vertical;
}
.contact-form input:focus,
.contact-form textarea:focus { outline: 2px solid var(--primary); outline-offset: 1px; }

/* ---------------------------------------------------------------------------
   13. Footer
   ------------------------------------------------------------------------- */
.site-footer { background: var(--bg-soft); border-top: 1px solid var(--border); padding: 56px 0 28px; margin-top: 40px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.footer-logo { font-weight: 700; font-size: 1.3rem; color: var(--text); }
.footer-tagline { color: var(--text-soft); margin-top: 10px; max-width: 320px; }
.footer-nav ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-nav a { color: var(--text-soft); font-size: .95rem; }
.footer-nav a:hover { color: var(--primary); }
.footer-social { display: flex; gap: 10px; flex-wrap: wrap; align-content: flex-start; }
.footer-social a {
    width: 40px; height: 40px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--border); border-radius: 50%;
    background: var(--surface); color: var(--text-soft);
    font-size: .8rem; font-weight: 600;
    transition: transform var(--transition), border-color var(--transition), color var(--transition);
}
.footer-social a:hover { transform: translateY(-3px); border-color: var(--primary); color: var(--primary); }
.footer-bottom {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--border);
    color: var(--text-mute); font-size: .85rem; flex-wrap: wrap; gap: 8px;
}
.footer-bottom p { margin: 0; }

/* ---------------------------------------------------------------------------
   14. Utilities & animations
   ------------------------------------------------------------------------- */
.no-js [data-theme-toggle] { display: none; }

[data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .6s ease, transform .6s ease;
    will-change: opacity, transform;
}
[data-reveal].is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
    [data-reveal] { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------------------
   15. Responsive breakpoints
   ------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .intro-inner { grid-template-columns: 1fr; gap: 32px; }
    .about-grid { grid-template-columns: 1fr; }
    .about-side { position: static; }
}

@media (max-width: 860px) {
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .contact-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .footer-cta-card { flex-direction: column; align-items: flex-start; }
    .footer-cta .signup-form { justify-content: flex-start; width: 100%; }

    /* Mobile nav */
    .nav-menu {
        position: fixed;
        inset: var(--header-h) 0 auto 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow);
        max-height: 0;
        overflow: hidden;
        transition: max-height var(--transition);
        margin: 0;
    }
    .nav-menu.is-open { max-height: 70vh; }
    .nav-list { flex-direction: column; align-items: stretch; padding: 16px; gap: 4px; }
    .nav-item a { display: block; padding: 12px 14px; font-size: 1rem; }
    .nav-burger { display: flex; }
    .nav-cta { display: none; }
}

@media (max-width: 560px) {
    body { font-size: 16px; }
    .section { padding: 56px 0; }
    .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; }
    .hero-stats { gap: 28px; }
    .post-meta > *::after,
    .post-card-meta > *::after { content: ""; margin: 0; }
    .pagination { flex-direction: column; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .contact-form-wrap { padding: 22px; }
}
