/* ===========================================================================
   Suzy — Ghost theme
   ---------------------------------------------------------------------------
   Retro/kawaii palette ported from the old Pelican "retroblog" theme.
   Everything you are likely to want to change lives in the :root block below.
   Change a token once and it updates everywhere.
   =========================================================================== */

@font-face {
    font-family: 'Comico-Regular';
    src: url('../fonts/comico/Comico-Regular.woff2') format('woff2'),
         url('../fonts/comico/Comico-Regular.woff') format('woff'),
         url('../fonts/comico/Comico-Regular.ttf') format('truetype');
    font-weight: 400;
    font-display: swap;
    font-style: normal;
}

@font-face {
    font-family: 'Figtree';
    src: url('../fonts/figtree/Figtree-Regular.ttf') format('truetype');
    font-weight: normal;
    font-display: swap;
    font-style: normal;
}

@font-face {
    font-family: 'Figtree';
    src: url('../fonts/figtree/Figtree-Bold.ttf') format('truetype');
    font-weight: bold;
    font-display: swap;
    font-style: normal;
}

:root {
    /* --- Brand ----------------------------------------------------------- */
    /* Ghost writes the accent colour you pick in admin into --ghost-accent-color */
    --accent: var(--ghost-accent-color, #EF0564);
    --accent-strong: #f00563;
    --accent-contrast: #ffffff;
    --header-text: #FCCF37;
    --header-text-hover: #daa805;
    --header-bg: #EFF5EE;

    /* --- Colour ---------------------------------------------------------- */
    --bg: #79BCC8;
    --bg-subtle: #f6f7f9;
    --text: pink;
    --text-muted: #5c6370;
    --border: var(--accent);
    --card-bg: #EFF5EE;
    --card-text: #274a71;

    /* --- Type ------------------------------------------------------------ */
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 "Helvetica Neue", Arial, sans-serif;
    --font-serif: Iowan Old Style, Apple Garamond, Baskerville,
                  "Times New Roman", serif;
    --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
    --font-comico: 'Comico-Regular', var(--font-sans);
    --font-figtree: 'Figtree', var(--font-sans);

    /* Ghost admin -> Design -> Brand can set fonts; those win when present. */
    --font-title: var(--gh-font-heading, var(--font-figtree));
    --font-body: var(--gh-font-body, var(--font-figtree));

    --text-base: 1.125rem;      /* body copy in feeds/UI */
    --text-post: 1.25rem;       /* body copy inside an article */
    --leading: 1.65;

    /* --- Layout ---------------------------------------------------------- */
    --wrap: 1200px;             /* feeds, header, footer */
    --wrap-narrow: 720px;       /* article measure */
    --gutter: 24px;
    --radius: 12px;

    /* --- Motion ---------------------------------------------------------- */
    --transition: 160ms ease;
}

/* Font choices exposed in Ghost admin → Design → Site-wide */
html.title-serif { --font-title: var(--gh-font-heading, var(--font-serif)); }
html.body-serif  { --font-body: var(--gh-font-body, var(--font-serif)); }

/* ---------------------------------------------------------------------------
   Reset / base
   --------------------------------------------------------------------------- */

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

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

body {
    margin: 0;
    background-color: var(--bg);
    background-image: url(../images/grid-white.png), url(../images/noise-light.png);
    background-repeat: repeat;
    color: var(--text);
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: var(--leading);
    -webkit-font-smoothing: antialiased;
    cursor: url(../images/DragonflyCMcursor.gif), auto;
}

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

a { color: inherit; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); }
a:hover { text-decoration-color: currentColor; }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-title);
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin: 0 0 0.5em;
   
}

p { margin: 0 0 1.2em; }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 100;
    padding: 12px 20px; background: var(--accent); color: var(--accent-contrast);
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------------------------------------------------------------------------
   Layout helpers
   --------------------------------------------------------------------------- */

.wrap {
    width: 100%;
    max-width: var(--wrap);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.wrap-narrow { max-width: var(--wrap-narrow); }

.site-main { padding-block: 48px 72px; }

.section-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 24px;
}

/* ---------------------------------------------------------------------------
   Buttons
   --------------------------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border: 1px solid transparent;
    border-radius: 999px;
    font: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: transform var(--transition), opacity var(--transition),
                background-color var(--transition), color var(--transition);
}
.btn:hover { transform: translateY(-1px); }

.btn-accent { background: var(--accent); color: var(--accent-contrast); }
.btn-accent:hover { opacity: 0.9; }

.btn-ghost { background: transparent; border-color: var(--border); color: var(--text); }
.btn-ghost:hover { background: var(--bg-subtle); }

.btn-lg { padding: 14px 28px; font-size: 1rem; }

/* "Outline" accent style, selectable in Ghost admin → Design */
.accent-outline .btn-accent {
    background: transparent;
    color: var(--accent);
    border-color: var(--accent);
}
.accent-outline .btn-accent:hover { background: var(--accent); color: var(--accent-contrast); }

/* ---------------------------------------------------------------------------
   Header + navigation
   --------------------------------------------------------------------------- */

.site-header {
    text-align: center;
    background: var(--header-bg);
    border-radius: 30px;
    /* harsh shadow, matching the old retro "sticker" look */
    box-shadow: 3px 4px 0px rgba(0, 0, 0, 0.25);
    margin: 16px auto 0px;
    max-width: 600px;
}

.site-header-inner {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 64px;
    padding-block: 8px;
}

.site-title {
    font-family: var(--font-title);
    font-size: 2em;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-decoration: none;
    color: var(--header-text);
}
.site-title:hover { color: var(--header-text-hover); }

.site-logo a {
    width:100px;
}

.site-logo img {
    max-height: 100px;
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    animation: spin 4s linear infinite;
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}


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

.nav-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-family:var(--font-comico);
    font-size: 1rem;
    font-weight: bold;
    text-decoration: none;
    color: var(--header-text);
    transition: color var(--transition);
}
.nav-item a:hover, .nav-current a { color: var(--header-text-hover); }

.nav-icon {
    display: block;
    width: 64px;
    height: 64px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
.nav-blog .nav-icon { background-image: url(../images/blog-static.png); }
.nav-blog a:hover .nav-icon { background-image: url(../images/blog.gif); }
.nav-projects .nav-icon { background-image: url(../images/sewing-static.png); }
.nav-projects a:hover .nav-icon { background-image: url(../images/sewing.gif); }
.nav-links .nav-icon { background-image: url(../images/links-static.png); }
.nav-links a:hover .nav-icon { background-image: url(../images/links.gif); }
.nav-contact .nav-icon { background-image: url(../images/bird-static.png); }
.nav-contact a:hover .nav-icon { background-image: url(../images/bird.gif); }

.nav-members { display: flex; align-items: center; gap: 16px; }
.nav-signin { font-size: 0.95rem; text-decoration: none; color: var(--header-text); }
.nav-signin:hover { color: var(--header-text-hover); }

/* CSS-only mobile menu toggle */
.nav-toggle-label { display: none; }

@media (max-width: 800px) {
    .nav-list {  gap: 14px; }
    .nav-item a { font-size: 1.05rem; }
}

/* ---------------------------------------------------------------------------
   Home hero
   --------------------------------------------------------------------------- */

.site-hero {
    position: relative;
    padding-block: 80px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.site-hero.has-cover { color: #fff; border-bottom: 0; }

.site-hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
}
.site-hero.has-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.35), rgba(0,0,0,0.6));
    z-index: -1;
}

.site-hero-title { font-size: clamp(2.2rem, 6vw, 3.5rem); margin-bottom: 12px; }

.site-hero-description {
    max-width: 46ch;
    margin-inline: auto;
    font-size: 1.15rem;
    opacity: 0.85;
}

/* ---------------------------------------------------------------------------
   Post feed
   --------------------------------------------------------------------------- */

.post-feed { display: grid; gap: 40px 32px; justify-items: center; }

.feed-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }

.feed-list { grid-template-columns: 1fr; max-width: var(--wrap-narrow); margin-inline: auto; }
.feed-list .post-card { display: grid; grid-template-columns: 200px 1fr; gap: 24px; align-items: start; }
.feed-list .post-card-image { margin-bottom: 0; }

@media (max-width: 600px) {
    .feed-list .post-card { grid-template-columns: 1fr; }
}

.post-card {
    position: relative;
    background: var(--card-bg);
    color: var(--card-text);
    border-radius: 8px;
    box-sizing: border-box;
    max-width: 500px;
}

/* Full-card click target, kept behind the text so links inside still work */
.post-card-link { position: absolute; inset: 0; z-index: 1; }

.post-card-image {
    margin: -16px -16px 18px;
    overflow: hidden;
    background: var(--bg-subtle);
    aspect-ratio: 16 / 10;
}
.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 400ms ease;
}
.post-card:hover .post-card-image img { transform: scale(1.03); }

.post-card-tag {
    display: inline-block;
    margin-bottom: 10px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
}

.post-card-title { 
   
    margin-bottom: 8px; 
    color: #fff;
    background: var(--accent-strong);
    padding: 12px;
    border-radius: 8px 8px 0 0;
}
.post-card-title span{
    display: inline-block;
  margin-left: 4px;
}
.post-card-title h2 {
    font-family: var(--font-figtree); 
    font-size: 1.35rem; 
    margin:0;
}

.post-card-excerpt {
    color: var(--text-muted);
    font-family: var(--font-figtree); 
    font-size: 1rem;
    margin-bottom: 14px;
}

.post-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    font-size: 1rem;
    font-weight:bold; 
    color:var(--accent-strong);
}

.post-card-body {
    padding: 16px;
}

.empty-state { text-align: center; color: var(--text-muted); padding-block: 80px; }

/* ---------------------------------------------------------------------------
   Archive headers (tag / author)
   --------------------------------------------------------------------------- */

.archive-header { text-align: center; padding: 0 0 24px 0; }
.archive-kicker {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    margin-bottom: 8px;
}
.archive-title { font-size: 1.7rem; }
.archive-description { max-width: 52ch; margin-inline: auto; color: var(--text-muted); }
.archive-avatar { width: 88px; height: 88px; border-radius: 50%; margin: 0 auto 20px; object-fit: cover; }
.archive-links { display: flex; justify-content: center; gap: 18px; font-size: 0.9rem; margin-bottom: 8px; }
.archive-count { font-size: 0.85rem; color: var(--text-muted); }

/* ---------------------------------------------------------------------------
   Single post
   --------------------------------------------------------------------------- */

article.post {
    background: var(--card-bg);
    color: var(--card-text);
    border-radius: 16px;
    max-width: 500px;
    margin-inline: auto;
    box-sizing: border-box;
}
article.post.page {
  
    color: var(--card-text);

    max-width: 500px;
    background:none;
}

article.post.page h1 {font-size: 1.7rem;text-align:center;color:var(--text);}


article.post .wrap-narrow { max-width: none; }

.post-header { padding-inline:0; }
article.post .post-header {padding: 0 0 24px 0;}
article.post .post-content h2 {margin-top:0;}

.post-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    font-size: 0.85rem;
    color: var(--card-text);
    margin-bottom: 0;
}

.post-date {
    background: var(--accent-strong);
    color: #fff;
    font-weight: bold;
    display: block;
    width: 100%;
    padding: 8px 16px;
    margin-bottom: 16px;
    border-radius:16px 16px 0 0;
}

.post-tag {
    color: var(--accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.75rem;
    text-decoration: none;
}

.post-title { font-size: 1.5rem; color: var(--accent);  font-family: var(--font-figtree); padding:0 16px; }

.post-excerpt {
    font-size: 1.2rem;
    color: var(--card-text);
    max-width: 56ch;
    margin-inline: auto;
}

.post-authors { display: flex; justify-content: center; gap: 20px; margin-top: 24px; }
.author-chip { display: inline-flex; align-items: center; gap: 8px; font-size: 0.9rem; text-decoration: none; }
.author-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }

.post-feature-image {
    margin: 0 0 16px;
    max-width: none;
    padding-inline: 0;
}
.post-feature-image img { width: 100%; border-radius: 0; max-width: 100%; }
.post-feature-image figcaption {
    margin-top: 12px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--card-text);
}

/* ---------------------------------------------------------------------------
   Article content — styles Ghost's rendered editor output
   --------------------------------------------------------------------------- */

.post-content {
    font-size: 16px;
    font-weight:400;
    line-height: 1.2rem;
    font-family: var(--font-figtree);
    color: var(--card-text);
    padding: 0 16px;
}

.post-content > * { margin-bottom: 1.4em; }
.post-content img { max-width: 100%; }

.post-content h2 { font-family:var(--font-figtree); font-size: 1.75em; margin-top: 1.8em; }
.post-content h3 { font-family:var(--font-figtree); font-size: 1.35em; margin-top: 1.6em; }

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

.post-content ul, .post-content ol { padding-left: 1.4em; }
.post-content li { margin-bottom: 0.5em; }

.post-content blockquote {
    margin-inline: 0;
    padding-left: 1.2em;
    border-left: 3px solid var(--accent);
    font-style: italic;
    color: var(--text-muted);
}

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

.post-content code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    padding: 0.15em 0.4em;
    border-radius: 4px;
    background: var(--bg-subtle);
}
.post-content pre {
    padding: 20px;
    border-radius: var(--radius);
    background: #16181d;
    color: #eceef2;
    overflow-x: auto;
    font-size: 0.85rem;
    line-height: 1.6;
}
.post-content pre code { background: none; padding: 0; font-size: inherit; }

.post-content table { width: 100%; border-collapse: collapse; font-size: 0.95em; }
.post-content th, .post-content td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

.post-content figure { margin-inline: 0; }
.post-content figcaption {
    margin-top: 10px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.post-content img, .post-content .kg-image { border-radius: var(--radius); margin-inline: auto; }

/* Ghost's wide/full-width cards break out of the narrow measure */
.post-content .kg-width-wide {
    width: min(var(--wrap), 100vw - var(--gutter) * 2);
    margin-inline: calc(50% - min(var(--wrap), 100vw - var(--gutter) * 2) / 2);
}
.post-content .kg-width-full {
    width: 100vw;
    margin-inline: calc(50% - 50vw);
}
.post-content .kg-width-full img { border-radius: 0; }

.post-content .kg-callout-card {
    display: flex;
    gap: 12px;
    padding: 20px;
    border-radius: var(--radius);
    background: var(--bg-subtle);
}

.post-content .kg-bookmark-card a {
    display: flex;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    text-decoration: none;
}
.post-content .kg-bookmark-content { padding: 20px; }
.post-content .kg-bookmark-title { font-weight: 700; }
.post-content .kg-bookmark-description { color: var(--text-muted); font-size: 0.9rem; }

.post-content .kg-embed-card { display: flex; flex-direction: column; align-items: center; }
.post-content iframe { max-width: 100%; border-radius: var(--radius); }

.post-content .kg-gallery-row { display: flex; gap: 8px; }
.post-content .kg-gallery-image img { width: 100%; }

article.post.page .post-content {
    background: var(--card-bg);
    color: var(--card-text);
    border-radius: 16px;
    max-width: 500px;
    margin-inline: auto;
    box-sizing: border-box;
    padding:16px;
}
    

/* ---------------------------------------------------------------------------
   Post footer, subscribe, comments, read-next
   --------------------------------------------------------------------------- */

.post-footer { padding-top: 40px; padding-bottom:24px; }

.post-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 40px; }
.post-tags .post-tag {
    padding: 5px 12px;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-muted);
    letter-spacing: 0.04em;
}
.post-tags .post-tag:hover { color: var(--accent); border-color: var(--accent); }

.subscribe-cta {
    padding: 40px 32px;
    border-radius: var(--radius);
    background: #ccb8d6;
    text-align: center;
}
.subscribe-title { font-size: 1.5rem; margin-bottom: 6px; }
.subscribe-text { color: var(--text-muted); font-size: 0.95rem; }

.subscribe-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    max-width: 460px;
    margin-inline: auto;
}
.subscribe-input {
    flex: 1 1 240px;
    padding: 11px 16px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #fff;
    color: var(--card-text);
    font: inherit;
    font-size: 0.95rem;
}

/* Ghost's Portal toggles .success / .error classes on the form */
.subscribe-message { flex-basis: 100%; display: none; margin: 4px 0 0; font-size: 0.9rem; }
.subscribe-form.success .subscribe-message.success { display: block; color: var(--accent); }
.subscribe-form.error .subscribe-message.error { display: block; color: #d93025; }

.post-comments { padding-block: 56px; }

.read-next { padding-top: 64px; margin-top: 64px; border-top: 1px solid var(--border); }

/* ---------------------------------------------------------------------------
   Pagination
   --------------------------------------------------------------------------- */

.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 32px auto 0;
    font-size: 0.95rem;
    padding: 8px;
    max-width: 600px;
    background: var(--header-bg);
    border-radius: 30px;
    /* harsh shadow, matching the old retro "sticker" look */
    box-shadow: 3px 4px 0px rgba(0, 0, 0, 0.25);
    font-family: var(--font-comico);
}
.pagination-link { text-decoration: none; color: var(--accent); }
.pagination-link:hover { color: var(--text); }
.pagination-link.is-disabled { color: var(--text-muted); opacity: 0.4; }
.pagination-status { color: var(--text-muted); }

/* ---------------------------------------------------------------------------
   Error pages
   --------------------------------------------------------------------------- */

.error-page { text-align: center; padding-block: 80px; }
.error-code { font-family: var(--font-title); font-size: 4rem; font-weight: 700; color: var(--accent); margin: 0; }
.error-title { font-size: 1.75rem; }
.error-help { color: var(--text-muted); margin-bottom: 28px; }

/* ---------------------------------------------------------------------------
   Footer
   --------------------------------------------------------------------------- */

.site-footer {
    padding-block: 40px;
    font-size: 0.9rem;
    color: var(--header-text);
    text-align: center;
}
.site-footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}
.site-footer p { margin: 0; font-family:var(--font-comico); font-size:1.1rem;}
.site-footer a { text-decoration: none; color: var(--header-text); }
.site-footer a:hover { color: var(--header-text-hover); }
.site-footer-nav .nav-list { justify-content: center; gap: 18px; }
.site-footer-nav .nav-item a { color: var(--header-text); flex-direction: row; }
.site-footer-nav .nav-item a:hover { color: var(--header-text-hover); }

.site-footer-counter noscript img { display: inline-block;  }

/* ---------------------------------------------------------------------------
   Henry's Corner — recurring callout used inline in migrated post content
   --------------------------------------------------------------------------- */

.henrys-corner {
    margin: 2em 0;
    padding: 2.5em 1.5em 1em 1.5em;
    background: #f2e9c7;
    border: 2px dotted #dfd19a;
    border-radius: 12px;
    position: relative;
}

.henrys-corner::before {
    content: "";
    position: absolute;
    top: -18px;
    right: -32px;
    width: 70px;
    height: 70px;
    background-image: url(../images/henry.png);
    background-size: contain;
    background-repeat: no-repeat;
    transform-origin: center center;
    animation: hc-sway 1s infinite steps(1, end);
}

.henrys-corner::after {
    content: "Henry's Corner";
    position: absolute;
    top: 14px;
    left: 24px;
    white-space: nowrap;
    font-size: 0.8rem;
    font-family: var(--font-comico), sans-serif;
    font-weight: bold;
    color: #af3493;
}

@keyframes hc-sway {
    0%   { transform: rotate(-18deg); }
    50%  { transform: rotate(0deg); }
    100% { transform: rotate(-18deg); }
}

@media (max-width: 700px) {
    .site-footer-inner { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
