/* ============================================================
   Accents Publishing — main stylesheet
   Mobile-first, responsive. Warm literary palette, teal accent.
   ============================================================ */

/* ---- Custom properties ---- */
:root {
    /* Palette */
    --color-bg:          #F9F7F4;
    --color-bg-alt:      #F0EDE6;
    --color-surface:     #FFFFFF;
    --color-border:      #DDD7CC;
    --color-border-light:#EBE7E0;

    --color-text:        #3B3832;
    --color-text-light:  #6B6560;
    --color-heading:     #1E1D1A;

    --color-accent:      #2A6B5E;
    --color-accent-hover:#1F5449;
    --color-accent-light:#5BA494;

    --color-tagline:     #8B2020;  /* maroon — tagline theme accent only */

    --color-danger:      #8B2020;  /* muted red — semantic (e.g. cancelled) */
    --color-danger-bg:   #F5E9E9;  /* light red tint for danger backgrounds */

    /* Typography */
    --font-display: 'Cormorant', Georgia, 'Times New Roman', serif;
    --font-body:    'Source Sans 3', 'Segoe UI', system-ui, sans-serif;

    --text-base:  1.0625rem;  /* 17px */
    --text-sm:    0.875rem;
    --text-xs:    0.8125rem;
    --text-lg:    1.1875rem;
    --text-xl:    1.5rem;
    --text-2xl:   2rem;
    --text-3xl:   2.75rem;

    --leading:      1.65;
    --leading-tight:1.25;

    /* Spacing */
    --space-xs:  0.5rem;
    --space-sm:  0.75rem;
    --space-md:  1.25rem;
    --space-lg:  2rem;
    --space-xl:  3rem;
    --space-2xl: 5rem;

    /* Layout */
    --container-max: 1120px;
    --container-pad: 1.25rem;

    /* Misc */
    --radius:    4px;
    --radius-lg: 6px;
    --shadow:    0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-lg: 0 4px 12px rgba(0,0,0,0.08);
    --transition: 0.2s ease;
}

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

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

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: var(--leading);
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: var(--color-accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--color-accent-hover); }

/* ---- Container ---- */
.container {
    max-width: var(--container-max);
    margin-inline: auto;
    padding-inline: var(--container-pad);
}

/* ============================================================
   HEADER & NAV — logo icon only
   ============================================================ */
.site-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 3.75rem;
}

/* Logo — icon only */
.site-logo { display: flex; align-items: center; }
.logo-img  { height: 2.25rem; width: auto; }

/* Nav links */
.nav-list {
    list-style: none;
    display: flex;
    gap: var(--space-md);
    align-items: center;
}

.nav-link {
    font-family: var(--font-body);
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text-light);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: var(--space-xs) 0;
    border-bottom: 2px solid transparent;
    transition: color var(--transition), border-color var(--transition);
}
.nav-link:hover,
.nav-link.is-active {
    color: var(--color-heading);
    border-bottom-color: var(--color-accent);
}

/* Hamburger toggle (mobile) */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--space-xs);
    flex-direction: column;
    gap: 5px;
}
.nav-toggle-bar {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--color-heading);
    border-radius: 1px;
    transition: transform var(--transition), opacity var(--transition);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
    opacity: 0;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ============================================================
   MAIN
   ============================================================ */
.site-main {
    min-height: calc(100vh - 3.75rem - 14rem);
}

/* ============================================================
   HERO — landing page with background image
   ============================================================ */
.hero-band {
    position: relative;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}
.hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('../media/hero.jpg');
    background-size: cover;
    background-position: center;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(30,29,26,0.55) 0%, rgba(30,29,26,0.70) 100%);
}
.hero-content {
    position: relative;
    z-index: 1;
    padding: var(--space-2xl) var(--space-lg);
}
.hero-name {
    font-family: var(--font-body);
    font-size: clamp(2rem, 5vw, 2.75rem);
    font-weight: 600;
    line-height: 1.05;
    color: #fff;
    text-transform: lowercase;
    letter-spacing: -0.01em;
    text-shadow: 0 2px 12px rgba(0,0,0,0.3);
}
.hero-tagline {
    font-family: var(--font-body);
    font-size: 1rem;
    color: #C4787A;   /* light maroon — echoes the banner tagline */
    letter-spacing: 0.03em;
    margin-top: 0.15rem;
    text-shadow: 0 1px 8px rgba(0,0,0,0.4);
}

/* ============================================================
   PAGE SECTIONS & HEADINGS
   ============================================================ */
.page-section {
    padding-block: var(--space-xl);
}
.page-section + .page-section {
    border-top: 1px solid var(--color-border-light);
}
.page-section--alt {
    background: var(--color-bg-alt);
}

.page-title {
    font-family: var(--font-display);
    font-size: var(--text-3xl);
    font-weight: 600;
    color: var(--color-heading);
    line-height: var(--leading-tight);
    margin-bottom: var(--space-lg);
}

.section-heading {
    font-family: var(--font-display);
    font-size: var(--text-2xl);
    font-weight: 600;
    color: var(--color-heading);
    line-height: var(--leading-tight);
    margin-bottom: var(--space-md);
}

.section-subheading {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: 600;
    color: var(--color-heading);
    line-height: var(--leading-tight);
    margin-bottom: var(--space-sm);
}

/* ============================================================
   BOOK PAGE
   ============================================================ */

/* Hero: cover + description side by side */
.book-hero {
    display: grid;
    gap: var(--space-xl);
    padding-block: var(--space-xl);
}
.book-cover {
    justify-self: center;
}
.book-cover img {
    max-width: 320px;
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
}
.book-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}
.book-title {
    font-family: var(--font-display);
    font-size: var(--text-3xl);
    font-weight: 700;
    color: var(--color-heading);
    line-height: var(--leading-tight);
    letter-spacing: -0.015em;
}
.book-author-line {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    color: var(--color-text-light);
    font-style: italic;
}
.book-author-line a {
    color: var(--color-text-light);
    border-bottom: 1px solid var(--color-border);
}
.book-author-line a:hover {
    color: var(--color-accent);
    border-bottom-color: var(--color-accent);
}
.book-meta {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs) var(--space-md);
}
.book-meta span::before {
    content: '·';
    margin-right: var(--space-xs);
    color: var(--color-border);
}
.book-meta span:first-child::before {
    display: none;
}
.book-description {
    line-height: var(--leading);
}
.book-description p + p {
    margin-top: var(--space-sm);
}

/* Tags */
.book-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs);
}
.book-tag {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-accent);
    background: rgba(42, 107, 94, 0.08);
    padding: 0.2em 0.65em;
    border-radius: 3px;
    letter-spacing: 0.02em;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.75em 1.75em;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: background var(--transition), transform 0.1s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
    background: var(--color-accent);
    color: #fff;
}
.btn-primary:hover {
    background: var(--color-accent-hover);
    color: #fff;
}
.btn-secondary {
    background: transparent;
    color: var(--color-accent);
    border: 1px solid var(--color-accent);
}
.btn-secondary:hover {
    background: rgba(42, 107, 94, 0.06);
    color: var(--color-accent-hover);
}

/* Out of print notice */
.book-oop {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    font-style: italic;
}

/* ---- Sample poem ---- */
.sample-block {
    padding: var(--space-lg) var(--space-xl);
    background: var(--color-surface);
    border-left: 3px solid var(--color-accent-light);
    border-radius: 0 var(--radius) var(--radius) 0;
}
.sample-block + .sample-block {
    margin-top: var(--space-lg);
}
.sample-title {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: 700;
    font-style: italic;
    color: var(--color-heading);
    margin-bottom: var(--space-md);
}
.sample-body {
    font-family: var(--font-display);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--color-text);
}
/* Each line span renders as its own line; raw newlines in the
   markup collapse instead of stacking with the structure. */
.sample-body .line {
    display: block;
}
.sample-body .stanza + .stanza {
    margin-top: 1em;
}

/* ---- Blurbs ---- */
.blurbs-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}
.blurb {
    position: relative;
    padding-left: var(--space-lg);
}
.blurb::before {
    content: '\201C';
    position: absolute;
    left: 0;
    top: -0.15em;
    font-family: var(--font-display);
    font-size: 3rem;
    color: var(--color-accent-light);
    line-height: 1;
}
.blurb-text {
    font-style: italic;
    line-height: var(--leading);
}
.blurb-credit {
    margin-top: var(--space-xs);
    font-size: var(--text-sm);
    color: var(--color-text-light);
}

/* ---- Book sections (Contributors, Awards, etc.) ---- */
.book-section {
    padding-block: var(--space-md);
}
.book-section h3 {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: 600;
    color: var(--color-heading);
    margin-bottom: var(--space-sm);
}

/* ---- Author bio on book page ---- */
.author-bio-card {
    display: flex;
    gap: var(--space-lg);
    align-items: flex-start;
    padding: var(--space-lg);
    background: var(--color-bg-alt);
    border-radius: var(--radius-lg);
}
.author-bio-photo {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}
.author-bio-content {
    flex: 1;
}
.author-bio-content h3 {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: 600;
    margin-bottom: var(--space-xs);
}
.author-bio-content h3 a {
    color: var(--color-heading);
}
.author-bio-content h3 a:hover {
    color: var(--color-accent);
}
.author-bio-text {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    line-height: var(--leading);
}
.author-bio-text p + p {
    margin-top: var(--space-xs);
}

/* ============================================================
   BOOKS LISTING (grid / list)
   ============================================================ */
.books-controls {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm) var(--space-md);
    align-items: center;
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--color-border-light);
}
.books-controls label {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-light);
    font-weight: 600;
}
.books-controls select {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    padding: 0.4em 0.8em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    color: var(--color-text);
}
.books-controls-search {
    display: contents;   /* lets the form's own children join the .books-controls flex row */
}
.books-controls input[type="search"] {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    padding: 0.4em 0.8em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    color: var(--color-text);
    min-width: 200px;
}

/* Shared search form (books, podcast): label + text input + submit + clear link */
.search-form {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
    align-items: center;
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--color-border-light);
}
.search-form label {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-light);
    font-weight: 600;
}
.search-form input[type="search"] {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    padding: 0.4em 0.8em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    color: var(--color-text);
    min-width: 240px;
    flex: 1 1 240px;
}
.search-form-clear {
    font-size: var(--text-sm);
    color: var(--color-text-light);
}

.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: var(--space-lg);
}
.book-card {
    text-align: center;
}
.book-card-cover {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: var(--space-sm);
    transition: box-shadow var(--transition), transform var(--transition);
}
.book-card:hover .book-card-cover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}
.book-card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.book-card-title {
    font-family: var(--font-display);
    font-size: var(--text-base);
    font-weight: 600;
    color: var(--color-heading);
    line-height: var(--leading-tight);
}
.book-card-author {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    margin-top: 0.15em;
}

/* List view */
.books-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}
.book-list-item {
    display: flex;
    gap: var(--space-md);
    align-items: flex-start;
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--color-border-light);
}
.book-list-item:last-child {
    border-bottom: none;
}
.book-list-cover {
    flex-shrink: 0;
    width: 80px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.book-list-info {
    flex: 1;
}
.book-list-title {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--color-heading);
}
.book-list-author {
    font-size: var(--text-sm);
    color: var(--color-text-light);
}
.book-list-desc {
    font-size: var(--text-sm);
    color: var(--color-text);
    margin-top: var(--space-xs);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ============================================================
   AUTHORS LISTING
   ============================================================ */
.authors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-lg);
}
.author-card {
    text-align: center;
}
.author-card-photo {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    margin-inline: auto;
    margin-bottom: var(--space-sm);
    box-shadow: var(--shadow);
}
.author-card-name {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--color-heading);
}

/* ============================================================
   LANDING PAGE BANDS
   ============================================================ */
.band-title {
    font-family: var(--font-display);
    font-size: var(--text-2xl);
    font-weight: 600;
    color: var(--color-heading);
    margin-bottom: var(--space-md);
}
.band-more {
    margin-top: var(--space-md);
    font-size: var(--text-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.featured-label {
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: var(--space-xs);
}

/* ============================================================
   FOOTER — brand + contact + mailing list
   ============================================================ */
.site-footer {
    background: var(--color-heading);
    color: rgba(255,255,255,0.7);
    padding-block: var(--space-xl) var(--space-lg);
}
.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-xl);
    padding-bottom: var(--space-lg);
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-name {
    font-family: var(--font-body);
    font-size: var(--text-xl);
    font-weight: 600;
    color: #fff;
    text-transform: lowercase;
}
.footer-tagline {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    color: var(--color-tagline);
    margin-top: 0.1rem;
}
.footer-contact {
    margin-top: var(--space-md);
    font-size: var(--text-sm);
    color: rgba(255,255,255,0.5);
    line-height: 1.6;
}
.footer-contact a {
    color: rgba(255,255,255,0.65);
}
.footer-contact a:hover {
    color: #fff;
}

.footer-signup-title {
    font-size: var(--text-sm);
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-sm);
}
.footer-signup-form {
    display: flex;
}
.footer-input {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    padding: 0.6em 0.9em;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-right: none;
    border-radius: var(--radius) 0 0 var(--radius);
    color: #fff;
    width: 220px;
    outline: none;
}
.footer-input::placeholder {
    color: rgba(255,255,255,0.35);
}
.footer-input:focus {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.3);
}
.footer-submit {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.6em 1.2em;
    background: var(--color-accent);
    color: #fff;
    border: 1px solid var(--color-accent);
    border-radius: 0 var(--radius) var(--radius) 0;
    cursor: pointer;
    transition: background var(--transition);
}
.footer-submit:hover {
    background: var(--color-accent-hover);
}
.footer-signup-note {
    font-size: var(--text-xs);
    color: rgba(255,255,255,0.3);
    margin-top: var(--space-xs);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-md);
}
.footer-copy {
    font-size: var(--text-xs);
    color: rgba(255,255,255,0.3);
}
.footer-links {
    display: flex;
    gap: var(--space-md);
}
.footer-links a {
    font-size: var(--text-sm);
    color: rgba(255,255,255,0.45);
}
.footer-links a:hover {
    color: rgba(255,255,255,0.8);
}

/* ============================================================
   UTILITY
   ============================================================ */
.visually-hidden {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    border: 0;
}

/* ============================================================
   RESPONSIVE — tablet (640px+)
   ============================================================ */
@media (min-width: 640px) {
    .book-hero {
        grid-template-columns: auto 1fr;
        align-items: start;
    }
    .book-cover {
        justify-self: start;
    }
    .author-bio-card {
        gap: var(--space-xl);
    }
    .author-bio-photo {
        width: 130px;
        height: 130px;
    }
}

/* ============================================================
   RESPONSIVE — desktop (900px+)
   ============================================================ */
@media (min-width: 900px) {
    :root {
        --container-pad: 2rem;
    }
    .book-cover img {
        max-width: 360px;
    }
    .books-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

/* ============================================================
   RESPONSIVE — mobile nav (<640px)
   ============================================================ */
@media (max-width: 639px) {
    .nav-toggle {
        display: flex;
    }
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--color-surface);
        border-bottom: 1px solid var(--color-border);
        box-shadow: var(--shadow-lg);
        padding: var(--space-md) var(--container-pad);
    }
    .site-nav.is-open {
        display: block;
    }
    .nav-list {
        flex-direction: column;
        gap: 0;
    }
    .nav-link {
        display: block;
        padding: var(--space-sm) 0;
        border-bottom: 1px solid var(--color-border-light);
    }
    .nav-link:last-child {
        border-bottom: none;
    }
    .footer-top {
        flex-direction: column;
    }
    .footer-input {
        width: 100%;
        min-width: 0;
    }
}

/* ============================================================
   PRINT
   ============================================================ */
@media print {
    .site-header, .site-footer, .nav-toggle, .btn { display: none; }
    .site-main { padding: 0; }
    body { font-size: 12pt; color: #000; background: #fff; }
}

/* ============================================================
   HOME BANDS — 3-up books with buy buttons, recent authors
   ============================================================ */
.btn-sm {
    font-size: var(--text-xs);
    padding: 0.55em 1.3em;
}
.books-grid--home {
    grid-template-columns: repeat(auto-fit, minmax(200px, 260px));
    justify-content: space-evenly;
    gap: var(--space-xl);
}
.book-card-buy {
    margin-top: var(--space-xs);
}
.authors-grid--home {
    grid-template-columns: repeat(auto-fit, minmax(180px, 220px));
    justify-content: space-evenly;
    gap: var(--space-xl);
}
.author-card-photo--empty {
    background: var(--color-border-light);
}


/* ============================================================
   CONTACT FORM
   ============================================================ */
.contact-container {
    max-width: 680px;
}
.contact-intro {
    margin-bottom: var(--space-lg);
}
.contact-form {
    background: var(--color-surface);
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: var(--space-xl);
}
.contact-form .form-grid {
    display: grid;
    gap: var(--space-md);
}
.contact-form .form-row {
    display: flex;
    flex-direction: column;
}
.contact-form label {
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--color-text-light);
    margin-bottom: 0.4rem;
}
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    width: 100%;
    font-family: var(--font-body);
    font-size: var(--text-base);
    padding: 0.7em 0.9em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-bg);
    color: var(--color-text);
    transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    background: var(--color-surface);
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(42, 107, 94, 0.12);
}
.contact-form textarea {
    resize: vertical;
    min-height: 10rem;
}
.contact-form .form-actions {
    margin-top: var(--space-md);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
}
.contact-form .form-note {
    font-size: var(--text-xs);
    color: var(--color-text-light);
}
@media (min-width: 640px) {
    .contact-form .form-grid--pair {
        grid-template-columns: 1fr 1fr;
    }
}
.form-row-hp {
    position: absolute;
    left: -9999px;
    top: -9999px;
}
.form-success {
    padding: var(--space-md) var(--space-lg);
    background: rgba(42, 107, 94, 0.08);
    border-left: 3px solid var(--color-accent);
    border-radius: 0 var(--radius) var(--radius) 0;
}
.form-error {
    padding: var(--space-md) var(--space-lg);
    background: rgba(139, 32, 32, 0.06);
    border-left: 3px solid #8B2020;
    border-radius: 0 var(--radius) var(--radius) 0;
    margin-bottom: var(--space-md);
}

/* Book subtitle */
.book-subtitle {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    color: var(--color-text-light);
    margin-top: -0.5rem;
}
.book-order {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
    align-items: center;
}

/* Draft preview banner (admin-only view) */
.draft-preview-banner {
    background: #FFF3D6;
    border: 1px solid #E0C878;
    color: #7A5C00;
    font-size: var(--text-sm);
    font-weight: 600;
    padding: 0.6rem 1rem;
    border-radius: var(--radius);
    margin-bottom: var(--space-lg);
}
.draft-preview-banner a {
    color: #7A5C00;
    text-decoration: underline;
}

/* ---- Event / class status tags (added for events+classes) ---- */
/* "Cancelled" uses a muted red (semantic, not a theme color); "Full" uses teal. */
.event-cancelled-tag,
.class-full-tag {
    display: inline-block;
    font-family: 'Source Sans 3', system-ui, sans-serif;
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1;
    padding: 0.28em 0.6em;
    border-radius: 999px;
    vertical-align: middle;
}
.event-cancelled-tag {
    color: var(--color-danger);
    background: var(--color-danger-bg);
    border: 1px solid var(--color-danger);
}
.class-full-tag {
    color: #fff;
    background: var(--color-accent);
}
.event-cancelled-notice {
    font-weight: 600;
    color: var(--color-danger);
    background: var(--color-danger-bg);
    border-left: 3px solid var(--color-danger);
    padding: var(--space-sm) var(--space-md);
    border-radius: 4px;
    margin-bottom: var(--space-md);
}

/* ---- Inline content images (book sections, event sections, editable pages) ---- */
.book-section img,
.book-description img,
.sample-body img {
    max-width: 100%;
    height: auto;
}

/* ---- Per-event mailing signup ---- */
.event-signup {
    margin-top: var(--space-xl);
    padding: var(--space-lg);
    background: var(--color-bg-alt);
    border-radius: var(--radius);
}
.event-signup-title {
    font-family: var(--font-display, Cormorant, Georgia, serif);
    font-size: var(--text-lg);
    margin: 0 0 var(--space-sm);
}
.event-signup-form {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
    align-items: center;
}
.event-signup-input {
    flex: 1;
    min-width: 220px;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--color-border, #d8d2c8);
    border-radius: var(--radius);
    font: inherit;
}
.event-signup-note {
    margin: var(--space-sm) 0 0;
    font-size: var(--text-sm);
    color: var(--color-muted, #6b655c);
}

/* ---- Footer newsletter link (hosted phpList subscribe page) ---- */
.footer-signup-btn {
    display: inline-block;
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.6em 1.2em;
    background: var(--color-accent);
    color: #fff;
    border: 1px solid var(--color-accent);
    border-radius: var(--radius);
    text-decoration: none;
    transition: background var(--transition);
}
.footer-signup-btn:hover {
    background: var(--color-accent-hover);
    color: #fff;
}

/* ============================================================
   Book tag filter (additive, AND semantics, live counts)
   ============================================================ */
.tag-filter {
    margin: 0.75rem 0 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}
.tag-filter-active,
.tag-filter-available {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.5rem;
}
.tag-filter-label {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-light);
    font-weight: 600;
    margin-right: 0.3rem;
}
.tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35em;
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-accent);
    background: rgba(42, 107, 94, 0.08);
    padding: 0.28em 0.7em;
    border-radius: 999px;
    border: 1px solid transparent;
    letter-spacing: 0.02em;
    transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.tag-chip:hover {
    background: rgba(42, 107, 94, 0.16);
    color: var(--color-accent-hover);
}
.tag-chip-n {
    font-weight: 500;
    color: var(--color-text-light);
    font-size: 0.85em;
}
.tag-chip-on {
    background: var(--color-accent);
    color: #fff;
}
.tag-chip-on:hover {
    background: var(--color-accent-hover);
    color: #fff;
}
.tag-chip-x { font-size: 0.85em; opacity: 0.85; }
.tag-filter-clear {
    font-size: var(--text-xs);
    color: var(--color-text-light);
    text-decoration: underline;
    margin-left: 0.25rem;
}
.tag-filter-clear:hover { color: var(--color-accent); }
.tag-filter-none {
    font-size: var(--text-xs);
    color: var(--color-text-light);
    margin: 0;
}

/* ============================================================
   Author A–Z strip + grouped sections
   ============================================================ */
.az-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem;
    margin: 0.5rem 0 2rem;
    padding-top: 0.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
    /* Pin the strip just below the sticky site header (3.75rem tall) so it
       stays reachable while scrolling a long author list. z-index sits under
       the header's 100; the page-bg fill keeps scrolled cards from showing
       through the gaps between letters. */
    position: sticky;
    top: 3.75rem;
    z-index: 90;
    background: var(--color-bg);
}
.az-letter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.9em;
    height: 1.9em;
    font-weight: 600;
    font-size: var(--text-sm);
    border-radius: 4px;
    color: var(--color-accent);
}
.az-letter:hover { background: rgba(42, 107, 94, 0.10); }
.az-letter-empty {
    color: var(--color-border);
    pointer-events: none;
}
.az-group { margin-bottom: 2.5rem; }
.az-group-heading {
    font-size: var(--text-lg);
    color: var(--color-heading);
    border-bottom: 2px solid var(--color-accent);
    display: inline-block;
    padding: 0 0.4em 0.1em 0.1em;
    margin: 0 0 1.25rem;
    scroll-margin-top: 8rem;   /* clears both the sticky header (3.75rem) and the pinned A–Z strip below it */
}

/* ============================================================
   Podcast page — /podcast
   ============================================================ */

/* Three-slot intro: banner-left | editable prose | banner-right.
   Stacks to a single column on narrow screens. The left banner is contained
   (never cropped, for a logo-type image); the right banner is
   cover-cropped to a fixed slot (for a photo-type image). */
.podcast-intro {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--color-border-light);
}
.podcast-intro-banner-left img {
    width: 160px;
    height: 160px;
    object-fit: contain;   /* show the whole logo */
    border-radius: var(--radius);
}
.podcast-intro-banner-right img {
    width: 160px;
    height: 160px;
    object-fit: cover;     /* fill + center-crop a photo */
    border-radius: var(--radius);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}
.podcast-intro-text .page-title { margin-bottom: 0.5rem; }

@media (max-width: 720px) {
    .podcast-intro {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
        gap: 1.25rem;
    }
    .podcast-intro-text { order: 3; text-align: left; }
    .podcast-intro-banner-right { order: 2; }
}

/* Episode list */
.podcast-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.podcast-episode {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 1.5rem;
    padding: 1.75rem 0;
    border-bottom: 1px solid var(--color-border-light);
    scroll-margin-top: 4.5rem;   /* clears the sticky header (3.75rem) when linked to via #ep-{id} */
}
.podcast-episode:last-child { border-bottom: none; }
.podcast-episode-img img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    object-position: 50% 10%;   /* bias toward the top so faces in tall portraits aren't cropped off */
    border-radius: var(--radius);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.15);
}
.podcast-episode-title {
    font-size: var(--text-lg);
    color: var(--color-heading);
    margin: 0 0 0.25rem;
    line-height: 1.25;
}
.podcast-episode-meta {
    font-size: var(--text-sm);
    color: var(--color-muted);
    margin: 0 0 0.6rem;
}
.podcast-episode-meta a { color: var(--color-accent); }
.podcast-episode-desc { margin: 0 0 0.75rem; }
.podcast-episode-audio {
    width: 100%;
    max-width: 34rem;
    height: 40px;
    margin-bottom: 0.5rem;
}
.podcast-episode-links {
    font-size: var(--text-sm);
    margin: 0;
}
.podcast-episode-links a { color: var(--color-accent); font-weight: 600; }

@media (max-width: 560px) {
    .podcast-episode {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }
    .podcast-episode-img img { width: 96px; height: 96px; }
}
