/* =====================================================================
   IN HAUS — blog & single post templates (page-specific layer).
   Tokens (--ih-*) from css/ih-tokens.css. Hex values here are only
   fallbacks or rgba photo/glass overlays (allowed by spec).
   ===================================================================== */

/* ---------------------------------------------------------------------
   0. ROOTS — sit above the unified background (body::before z-index:0)
   --------------------------------------------------------------------- */
.ih-archive,
.ih-single {
    position: relative;
    z-index: 1;
}

.ih-archive .container,
.ih-single .container {
    max-width: 1280px;
}

/* reveal / hover (mirror of blog-grid pattern, scoped to templates) */
.ih-archive [data-reveal],
.ih-single [data-reveal] {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.9s cubic-bezier(.16, .84, .36, 1), transform 0.9s cubic-bezier(.16, .84, .36, 1);
}

.ih-archive [data-reveal].is-visible,
.ih-single [data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------------------------------------------------------------------
   1. SHARED BITS — breadcrumb, eyebrow
   --------------------------------------------------------------------- */
.ih-breadcrumb {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #9b8c72;
    margin-bottom: 4px;
}

.ih-breadcrumb a {
    color: #9b8c72;
    text-decoration: none;
}

.ih-breadcrumb a:hover {
    color: var(--ih-accent-text, #9A5E00);
}

.ih-breadcrumb .separator {
    opacity: 0.5;
    margin: 0 8px;
}

.ih-breadcrumb .last,
.ih-breadcrumb .rank-math-breadcrumb p > span:last-child {
    color: var(--ih-accent-text, #9A5E00);
}

.ih-breadcrumb p {
    margin: 0;
}

.ih-eyebrow {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: #b08a52;
}

/* ---------------------------------------------------------------------
   2. ARCHIVE — page head
   --------------------------------------------------------------------- */
.ih-archive__head {
    padding: 56px 0 8px;
}

.ih-archive__title {
    margin: 14px 0 0;
    font-size: clamp(30px, 5vw, 54px);
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    letter-spacing: -0.02em;
    line-height: 1.05;
}

.ih-archive__lead {
    margin: 18px 0 0;
    font-size: 17px;
    line-height: 1.6;
    color: var(--ih-text-muted, #706A60);
    max-width: 620px;
}

/* chips */
.ih-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 32px;
}

.ih-chip {
    padding: 10px 20px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(122, 106, 80, 0.2);
    color: #5c5447;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.ih-chip:hover {
    border-color: var(--ih-primary, #eb9315);
    color: var(--ih-accent-text, #9A5E00);
}

.ih-chip.is-active {
    background: var(--ih-primary, #eb9315);
    border-color: var(--ih-primary, #eb9315);
    color: #fff;
    font-weight: 700;
}

/* ---------------------------------------------------------------------
   3. FEATURED
   --------------------------------------------------------------------- */
.ih-archive__featured {
    padding: 36px 0 8px;
}

.ih-featured {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    border-radius: 24px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 30px 80px -46px rgba(24, 20, 8, 0.5);
    text-decoration: none;
    transition: transform 0.6s cubic-bezier(.16, .84, .36, 1), box-shadow 0.6s ease;
}

.ih-featured.is-hover {
    transform: translateY(-6px);
    box-shadow: 0 0 0 3px rgba(235, 147, 21, 0.5), 0 40px 96px -46px rgba(235, 147, 21, 0.4), 0 40px 96px -46px rgba(24, 20, 8, 0.55);
}

.ih-featured__media {
    position: relative;
    min-height: 320px;
    overflow: hidden;
}

.ih-featured__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.1s cubic-bezier(.16, .84, .36, 1), filter 0.8s ease;
    filter: saturate(0.9) contrast(1.02);
}

.ih-featured.is-hover .ih-featured__img {
    transform: scale(1.04);
    filter: saturate(1.02) brightness(1.03);
}

.ih-featured__grad {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(120deg, rgba(24, 16, 6, 0.18) 0%, rgba(24, 16, 6, 0) 60%);
}

.ih-featured__badge {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 8px 16px;
    border-radius: 999px;
    background: var(--ih-primary, #eb9315);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.ih-featured__body {
    padding: 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ih-featured__meta {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ih-accent, #eb9315);
}

.ih-featured__title {
    margin: 16px 0 0;
    font-size: clamp(22px, 2.5vw, 30px);
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    letter-spacing: -0.01em;
    line-height: 1.18;
}

.ih-featured__excerpt {
    margin: 16px 0 0;
    font-size: 15px;
    line-height: 1.65;
    color: #736d62;
}

.ih-featured__more {
    margin-top: 26px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--ih-accent-text, #9A5E00);
    font-size: 14px;
    font-weight: 600;
}

/* ---------------------------------------------------------------------
   4. POST CARD (copied from blog-grid.css so it works without the block)
   --------------------------------------------------------------------- */
.post-card {
    display: block;
    height: 100%;
    text-decoration: none;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 18px 44px -34px rgba(24, 20, 8, 0.45);
    transition: transform 0.6s cubic-bezier(.16, .84, .36, 1), box-shadow 0.6s ease;
}

.post-card__media {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.post-card__thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: filter 0.7s ease, transform 0.7s ease;
}

.post-card__placeholder {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(135deg, #efe7da 0 12px, #f4eee3 12px 24px);
}

.post-card__overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at 50% 40%, rgba(235, 147, 21, 0.12) 0%, rgba(235, 147, 21, 0) 62%);
}

.post-card__body {
    padding: 24px 22px 26px;
}

.post-card__cat {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ih-accent, #eb9315);
}

.post-card__title {
    margin: 12px 0 0;
    font-size: 18px;
    line-height: 1.34;
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card__excerpt {
    margin: 12px 0 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--ih-text-muted, #8a8378);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card__more {
    margin-top: 18px;
    font-size: 13px;
    font-weight: 600;
    color: var(--ih-accent-text, #9A5E00);
}

.post-card.is-hover {
    transform: translateY(-6px);
    box-shadow: 0 0 0 3px rgba(235, 147, 21, 0.55), 0 30px 70px -34px rgba(235, 147, 21, 0.5), 0 24px 60px -38px rgba(24, 20, 8, 0.5);
}

.post-card.is-hover .post-card__thumb {
    filter: brightness(1.04) saturate(1.1);
    transform: scale(1.04);
}

/* compact card (related) */
.post-card--compact .post-card__media {
    height: 180px;
}

.post-card--compact .post-card__title {
    margin-top: 10px;
    font-size: 16px;
    line-height: 1.36;
}

/* ---------------------------------------------------------------------
   5. LIST SECTION
   --------------------------------------------------------------------- */
.ih-archive__list {
    padding: 42px 0 16px;
}

.ih-archive__empty {
    color: var(--ih-text-muted, #706A60);
    font-size: 16px;
    padding: 24px 0;
}

/* ---------------------------------------------------------------------
   6. PAGINATION
   --------------------------------------------------------------------- */
.ih-pagination {
    margin-top: 40px;
}

.ih-pagination__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.ih-pagination .page-numbers {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(122, 106, 80, 0.2);
    color: #5c5447;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.ih-pagination a.page-numbers:hover {
    border-color: var(--ih-primary, #eb9315);
    color: var(--ih-accent-text, #9A5E00);
}

.ih-pagination .page-numbers.current {
    background: var(--ih-primary, #eb9315);
    border-color: var(--ih-primary, #eb9315);
    color: #fff;
    font-weight: 700;
}

.ih-pagination .page-numbers.dots {
    background: transparent;
    border-color: transparent;
    color: #9b8c72;
}

.ih-pagination .page-numbers.prev,
.ih-pagination .page-numbers.next {
    font-size: 16px;
    color: #9b8c72;
}

/* ---------------------------------------------------------------------
   7. CTA PLATE (shared — subscribe & post)
   --------------------------------------------------------------------- */
.ih-blog-cta-wrap,
.ih-post-cta-wrap {
    padding: 40px 0 96px;
}

.ih-cta-plate {
    position: relative;
    overflow: hidden;
    padding: 48px 56px;
    border-radius: 24px;
    background: linear-gradient(135deg, #1f1a12 0%, #2a2114 100%);
    box-shadow: 0 40px 90px -50px rgba(24, 16, 4, 0.7);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.ih-cta-plate__glow {
    position: absolute;
    top: -120px;
    right: -80px;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    pointer-events: none;
    background: radial-gradient(circle, rgba(235, 147, 21, 0.26) 0%, rgba(235, 147, 21, 0) 66%);
    filter: blur(10px);
}

.ih-cta-plate__text {
    position: relative;
    z-index: 2;
}

.ih-cta-plate__eyebrow {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--ih-accent-soft, #ffd9a0);
    margin-bottom: 12px;
}

.ih-cta-plate__title {
    margin: 0;
    font-size: clamp(22px, 3vw, 30px);
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.01em;
}

.ih-cta-plate__lead {
    margin: 12px 0 0;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.7);
}

.ih-cta-plate__action {
    position: relative;
    z-index: 2;
    flex: none;
}

/* subscribe form */
.ih-subscribe {
    display: flex;
    gap: 12px;
}

.ih-subscribe__input {
    width: 260px;
    height: 54px;
    padding: 0 18px;
    border-radius: 13px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.08);
    font-family: inherit;
    font-size: 14px;
    color: #fff;
    outline: none;
    transition: box-shadow 0.4s ease, border-color 0.4s ease;
}

.ih-subscribe__input::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

.ih-subscribe__input:focus {
    border-color: var(--ih-primary, #eb9315);
    box-shadow: 0 0 0 4px rgba(235, 147, 21, 0.22);
}

.ih-subscribe__btn {
    height: 54px;
    white-space: nowrap;
}

/* ---------------------------------------------------------------------
   8. SINGLE — head / byline / cover
   --------------------------------------------------------------------- */
.ih-single__head {
    padding: 56px 0 0;
}

.ih-single__head-inner {
    max-width: 820px;
    margin: 0 auto;
}

.ih-single .ih-eyebrow {
    margin-top: 24px;
    letter-spacing: 0.1em;
    color: var(--ih-accent, #eb9315);
}

.ih-single__title {
    margin: 14px 0 0;
    font-size: clamp(28px, 4.4vw, 46px);
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    letter-spacing: -0.02em;
    line-height: 1.12;
}

.ih-single__byline {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-top: 26px;
}

.ih-single__avatar {
    flex: none;
}

.ih-single__avatar img {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.ih-single__author {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--ih-ink, #18140E);
}

.ih-single__meta {
    display: block;
    font-size: 12.5px;
    color: var(--ih-text-muted, #8a8378);
    margin-top: 2px;
}

.ih-single__cover-wrap {
    padding: 36px 0 0;
}

.ih-single__cover {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
    height: clamp(280px, 38vw, 480px);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 30px 80px -46px rgba(24, 20, 8, 0.5);
}

.ih-single__cover-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.92) contrast(1.02);
}

.ih-single__cover-grad {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(24, 16, 6, 0.05) 0%, rgba(24, 16, 6, 0) 60%, rgba(24, 16, 6, 0.28) 100%);
}

/* ---------------------------------------------------------------------
   9. PROSE — the_content typography
   --------------------------------------------------------------------- */
.ih-single__body-wrap {
    padding: 56px 0 40px;
}

.ih-prose {
    max-width: 820px;
    margin: 0 auto;
}

.ih-prose p {
    margin: 26px 0 0;
    font-size: 17px;
    line-height: 1.78;
    color: #4a443b;
}

.ih-prose > p:first-of-type {
    margin-top: 0;
    font-size: 19px;
    line-height: 1.7;
    font-weight: 500;
    color: var(--ih-ink, #18140E);
}

.ih-prose h2 {
    margin: 44px 0 0;
    font-size: 28px;
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.ih-prose h3 {
    margin: 32px 0 0;
    font-size: 22px;
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    line-height: 1.25;
}

.ih-prose ul,
.ih-prose ol {
    margin: 18px 0 0;
    padding-left: 1.4em;
    font-size: 17px;
    line-height: 1.78;
    color: #4a443b;
}

.ih-prose li {
    margin-top: 8px;
}

.ih-prose li::marker {
    color: var(--ih-primary, #eb9315);
}

.ih-prose a {
    color: var(--ih-accent-text, #9A5E00);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ih-prose a:hover {
    color: var(--ih-accent-hover, #c9760a);
}

.ih-prose blockquote {
    margin: 40px 0;
    padding: 32px 36px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.6);
    border-left: 3px solid var(--ih-primary, #eb9315);
    box-shadow: 0 18px 44px -36px rgba(24, 20, 8, 0.35);
}

.ih-prose blockquote p {
    margin: 0;
    font-size: 22px;
    line-height: 1.5;
    font-weight: 600;
    font-style: italic;
    color: var(--ih-ink, #18140E);
}

.ih-prose img {
    border-radius: 18px;
    max-width: 100%;
    height: auto;
    margin: 32px 0;
    box-shadow: 0 24px 56px -38px rgba(24, 20, 8, 0.5);
}

.ih-prose figure {
    margin: 32px 0;
}

.ih-prose figure img {
    margin: 0;
}

.ih-prose figcaption {
    margin-top: 10px;
    font-size: 13px;
    color: var(--ih-text-muted, #706A60);
    text-align: center;
}

.ih-prose table {
    width: 100%;
    margin: 28px 0;
    border-collapse: collapse;
    font-size: 15px;
    color: #4a443b;
}

.ih-prose table th,
.ih-prose table td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(122, 106, 80, 0.18);
    text-align: left;
}

.ih-prose table th {
    color: var(--ih-ink, #18140E);
    font-weight: 600;
}

.ih-prose__pages {
    margin-top: 32px;
    font-size: 14px;
    color: var(--ih-text-muted, #706A60);
}

.ih-prose__pages a {
    color: var(--ih-accent-text, #9A5E00);
    padding: 0 6px;
}

/* ---------------------------------------------------------------------
   10. SHARE
   --------------------------------------------------------------------- */
.ih-share {
    max-width: 820px;
    margin: 48px auto 0;
    padding-top: 28px;
    border-top: 1px solid rgba(122, 106, 80, 0.18);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.ih-share__label {
    font-size: 13px;
    font-weight: 600;
    color: #5c5447;
    margin-right: 4px;
}

.ih-share__btn {
    position: relative;
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(122, 106, 80, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5c5447;
    cursor: pointer;
    text-decoration: none;
    transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.ih-share__btn:hover {
    border-color: var(--ih-primary, #eb9315);
    color: var(--ih-accent-text, #9A5E00);
}

.ih-share__copied {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 10px;
    border-radius: 8px;
    background: var(--ih-ink, #18140E);
    color: #fff;
    font-size: 11px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s;
}

.ih-share__btn--copy.is-copied .ih-share__copied {
    opacity: 1;
    visibility: visible;
}

/* ---------------------------------------------------------------------
   11. RELATED
   --------------------------------------------------------------------- */
.ih-related {
    padding: 40px 0;
}

.ih-related__head {
    margin-bottom: 32px;
}

.ih-related__title {
    margin: 14px 0 0;
    font-size: clamp(24px, 3.4vw, 34px);
    font-weight: 600;
    color: var(--ih-ink, #18140E);
    letter-spacing: -0.015em;
}

/* ---------------------------------------------------------------------
   12. RESPONSIVE
   --------------------------------------------------------------------- */
@media (max-width: 991.98px) {
    .ih-featured {
        grid-template-columns: 1fr;
    }

    .ih-featured__media {
        min-height: 240px;
    }

    .ih-featured__body {
        padding: 32px 28px;
    }

    .ih-archive__head {
        padding: 40px 0 4px;
    }

    .ih-single__head {
        padding: 40px 0 0;
    }
}

@media (max-width: 767.98px) {
    .ih-cta-plate {
        flex-direction: column;
        align-items: flex-start;
        padding: 36px 28px;
    }

    .ih-cta-plate__action,
    .ih-subscribe {
        width: 100%;
    }

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

    .ih-subscribe__input {
        width: 100%;
    }

    .ih-subscribe__btn {
        width: 100%;
    }

    .ih-prose p,
    .ih-prose ul,
    .ih-prose ol {
        font-size: 16px;
    }

    .ih-prose > p:first-of-type {
        font-size: 17.5px;
    }

    .ih-prose h2 {
        font-size: 24px;
    }

    .ih-prose blockquote {
        padding: 24px 24px;
    }

    .ih-prose blockquote p {
        font-size: 19px;
    }

    .ih-blog-cta-wrap,
    .ih-post-cta-wrap {
        padding: 32px 0 64px;
    }
}

/* ---------------------------------------------------------------------
   13. REDUCED MOTION
   --------------------------------------------------------------------- */
/* reduced-motion suppression removed: animations must always play (owner requirement) */
