:root {
    --em-bg: #f6f3ed;
    --em-surface: #ffffff;
    --em-text: #17211b;
    --em-muted: #66736b;
    --em-line: #e6dfd3;
    --em-brand: #0d7c66;
    --em-brand-dark: #075f50;
    --em-accent: #c89f54;
    --em-shadow: 0 14px 35px rgba(31, 45, 38, 0.10);
    --em-radius: 8px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--em-bg);
    color: var(--em-text);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.5;
}

a {
    color: inherit;
}

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

.em-page {
    min-height: 100vh;
}

.em-section {
    padding: 28px 0;
}

.em-wrap {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.em-hero {
    padding: 36px 0 24px;
    background: linear-gradient(135deg, #fffaf1 0%, #eef6f0 100%);
    border-bottom: 1px solid var(--em-line);
}

.em-hero-grid,
.em-form-grid,
.em-detail-grid {
    display: grid;
    gap: 24px;
}

.em-hero h1,
.em-list-head h1,
.em-detail-grid h1,
.em-summary h1 {
    margin: 8px 0 12px;
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 1.02;
    letter-spacing: 0;
}

.em-hero p,
.em-lead,
.em-final-cta p {
    margin: 0;
    color: var(--em-muted);
    font-size: 1.06rem;
}

.em-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.em-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 18px;
}

.em-stats div {
    padding: 16px;
    background: rgba(255, 255, 255, .84);
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    box-shadow: 0 10px 24px rgba(31, 45, 38, .08);
}

.em-stats strong {
    display: block;
    color: var(--em-brand-dark);
    font-size: clamp(2rem, 5vw, 3.2rem);
    line-height: .92;
    letter-spacing: 0;
}

.em-stats span {
    display: block;
    margin-top: 9px;
    color: var(--em-muted);
    font-size: .86rem;
    font-weight: 850;
    text-transform: uppercase;
}

.em-kicker {
    color: var(--em-brand);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.em-filter {
    display: grid;
    gap: 12px;
    padding: 16px;
    background: var(--em-surface);
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    box-shadow: var(--em-shadow);
}

.em-filter label,
.em-form label {
    display: grid;
    gap: 7px;
    color: var(--em-muted);
    font-size: .88rem;
    font-weight: 700;
}

.em-filter input,
.em-filter select,
.em-form input,
.em-form textarea {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    padding: 10px 12px;
    color: var(--em-text);
    background: #fff;
    font: inherit;
}

.em-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 11px 16px;
    border-radius: var(--em-radius);
    border: 1px solid transparent;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
}

.em-btn-primary {
    color: #fff;
    background: var(--em-brand);
}

.em-btn-primary:hover {
    background: var(--em-brand-dark);
}

.em-btn-outline {
    color: var(--em-brand);
    border-color: rgba(13, 124, 102, .28);
    background: #fff;
}

.em-btn-full {
    width: 100%;
}

.em-section-head,
.em-results-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.em-section-head h2,
.em-results-head h2,
.em-detail-block h2,
.em-form h2,
.em-book-box h2 {
    margin: 3px 0 0;
    font-size: clamp(1.45rem, 3vw, 2.2rem);
}

.em-link,
.em-back {
    color: var(--em-brand);
    font-weight: 800;
    text-decoration: none;
}

.em-back {
    display: inline-block;
    margin-bottom: 14px;
}

.em-type-grid,
.em-card-grid {
    display: grid;
    gap: 16px;
}

.em-type-card,
.em-card,
.em-summary,
.em-form,
.em-book-box {
    background: var(--em-surface);
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    box-shadow: var(--em-shadow);
    overflow: hidden;
}

.em-type-card {
    min-height: 190px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 16px;
    text-decoration: none;
}

.em-type-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.em-type-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.68));
    z-index: 1;
}

.em-type-card span,
.em-type-card small,
.em-type-card em {
    position: relative;
    z-index: 2;
    color: #fff;
}

.em-type-card span {
    font-size: 1.25rem;
    font-weight: 850;
}

.em-type-card em {
    width: max-content;
    margin-top: 6px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .18);
    font-size: .78rem;
    font-style: normal;
    font-weight: 850;
}

.em-card img {
    width: 100%;
    height: 210px;
    object-fit: cover;
}

.em-card-body,
.em-summary,
.em-form,
.em-book-box {
    padding: 16px;
}

.em-card h3 {
    margin: 12px 0 7px;
    font-size: 1.25rem;
}

.em-card p {
    min-height: 48px;
    margin: 0 0 14px;
    color: var(--em-muted);
}

.em-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.em-badge {
    display: inline-flex;
    align-items: center;
    min-height: 27px;
    padding: 5px 9px;
    border-radius: 999px;
    background: #f0eadf;
    color: #4c5b52;
    font-size: .76rem;
    font-weight: 800;
}

.em-badge-cta {
    background: rgba(13, 124, 102, .11);
    color: var(--em-brand-dark);
}

.em-meta,
.em-info-strip {
    display: grid;
    gap: 8px;
}

.em-meta {
    grid-template-columns: 1fr 1fr;
    margin-bottom: 14px;
    color: var(--em-muted);
    font-size: .92rem;
}

.em-meta span {
    display: grid;
    gap: 2px;
}

.em-meta b {
    color: var(--em-muted);
    font-size: .68rem;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.em-meta strong {
    display: grid;
    gap: 2px;
    grid-column: 1 / -1;
    color: var(--em-text);
    font-size: 1.7rem;
    line-height: 1.1;
}

.em-meta strong span,
.em-info-price em {
    color: var(--em-brand);
    font-size: .78rem;
    font-style: normal;
    font-weight: 950;
    letter-spacing: .08em;
}

.em-meta strong small,
.em-info-price small,
.em-book-price small {
    color: var(--em-muted);
    font-size: .82rem;
    font-weight: 800;
}

.em-soft {
    background: rgba(255, 255, 255, .42);
    border-top: 1px solid var(--em-line);
    border-bottom: 1px solid var(--em-line);
}

.em-list-head {
    background: #fffaf1;
    border-bottom: 1px solid var(--em-line);
}

.em-empty,
.em-empty-page {
    padding: 22px;
    background: var(--em-surface);
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
}

.em-gallery {
    display: grid;
    gap: 8px;
}

.em-gallery img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: var(--em-radius);
}

.em-gallery-main {
    height: 300px !important;
}

.em-detail-layout {
    padding-top: 0;
}

.em-info-strip {
    margin: 20px 0;
    padding: 14px;
    background: #fff;
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
}

.em-info-strip span,
.em-dl dt {
    color: var(--em-muted);
    font-size: .78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.em-info-strip strong,
.em-dl dd {
    margin: 0;
    color: var(--em-text);
    font-weight: 750;
}

.em-info-price strong {
    display: grid;
    gap: 2px;
    color: var(--em-text);
    font-size: 1.75rem;
    line-height: 1.05;
}

.em-why {
    margin: 20px 0;
    padding: 18px;
    background: #fff;
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    box-shadow: 0 10px 24px rgba(31, 45, 38, .07);
}

.em-why h2 {
    margin: 0 0 12px;
    font-size: 1.2rem;
    text-transform: uppercase;
}

.em-why ul {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.em-why li {
    position: relative;
    padding-left: 28px;
    font-weight: 800;
}

.em-why li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--em-brand);
    font-weight: 950;
}

.em-detail-block {
    padding: 20px 0;
    border-top: 1px solid var(--em-line);
}

.em-detail-block p {
    margin: 9px 0 0;
    color: #334139;
}

.em-dl {
    display: grid;
    gap: 12px;
    margin: 0;
}

.em-dl div {
    display: grid;
    gap: 4px;
}

.em-book-box {
    position: sticky;
    top: 16px;
    height: max-content;
    border-color: rgba(13, 124, 102, .25);
}

.em-book-box p {
    color: var(--em-muted);
}

.em-book-box h2 {
    font-size: 1.7rem;
    letter-spacing: .02em;
}

.em-book-subtitle {
    margin: 4px 0 16px;
    font-weight: 800;
}

.em-book-price {
    margin: 18px 0;
    padding: 18px 0;
    border-top: 1px solid var(--em-line);
    border-bottom: 1px solid var(--em-line);
}

.em-book-price span {
    display: block;
    color: var(--em-brand);
    font-size: .86rem;
    font-weight: 900;
    text-transform: uppercase;
}

.em-book-price strong {
    display: block;
    color: var(--em-text);
    font-size: 2.35rem;
    line-height: .98;
}

.em-book-status {
    display: inline-flex;
    margin: 0 0 16px;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(13, 124, 102, .11);
    color: var(--em-brand-dark);
    font-size: .82rem;
    font-weight: 850;
}

.em-book-facts {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 14px 0 0;
    border-top: 1px solid var(--em-line);
}

.em-book-facts div {
    display: grid;
    grid-template-columns: 88px 1fr;
    gap: 10px;
}

.em-book-facts dt {
    color: var(--em-muted);
    font-size: .76rem;
    font-weight: 850;
    text-transform: uppercase;
}

.em-book-facts dd {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 0;
    font-weight: 800;
}

.em-book-note {
    margin: 12px 0 0;
    font-size: .9rem;
}

.em-fields {
    display: grid;
    gap: 12px;
    margin: 16px 0;
}

.em-field-full {
    grid-column: 1 / -1;
}

.em-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.em-final-cta {
    padding: 24px;
    background: #fff;
    border: 1px solid var(--em-line);
    border-radius: var(--em-radius);
    text-align: center;
}

@media (min-width: 680px) {
    .em-filter,
    .em-fields,
    .em-info-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .em-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .em-filter .em-btn {
        align-self: end;
    }

    .em-type-grid,
    .em-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .em-gallery {
        grid-template-columns: 2fr 1fr 1fr;
    }

    .em-gallery-main {
        grid-row: span 2;
        height: 388px !important;
    }
}

@media (min-width: 960px) {
    .em-section {
        padding: 42px 0;
    }

    .em-hero-grid {
        grid-template-columns: 1.1fr .9fr;
        align-items: center;
    }

    .em-stats {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .em-filter-hero {
        grid-template-columns: 1fr;
    }

    .em-type-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .em-card-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .em-detail-grid {
        grid-template-columns: minmax(0, 1fr) 340px;
        align-items: start;
    }

    .em-form-grid {
        grid-template-columns: 360px minmax(0, 1fr);
        align-items: start;
    }
}

@media (max-width: 679px) {
    .em-section-head,
    .em-results-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .em-card p {
        min-height: 0;
    }

    .em-book-box {
        position: static;
    }
}
