.nursery-page {
    max-width: 1180px;
    margin: 0 auto 56px;
    padding: 0 18px;
}

.nursery-hero {
    margin: 28px 0 24px;
    padding: 28px;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.08);
}

.nursery-kicker {
    margin: 0 0 6px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.72;
}

.nursery-hero h1 {
    margin: 0 0 10px;
    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: 1.05;
}

.nursery-hero p:last-child {
    max-width: 820px;
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.65;
}

.nursery-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.nursery-card {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 18px;
    min-height: 230px;
    padding: 20px;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.08);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.nursery-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.12);
}

.nursery-card-logo-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 150px;
    border-radius: 18px;
    background: rgba(0, 0, 0, 0.035);
    overflow: hidden;
}

.nursery-card-logo {
    display: block;
    max-width: 100%;
    max-height: 150px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.nursery-card-logo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    border-radius: 999px;
    background: var(--bg-dark, #2f3a2f);
    color: #fff;
    font-size: 2.4rem;
    font-weight: 700;
    line-height: 1;
}

.nursery-card-body {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.nursery-card-headline {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.nursery-card h2 {
    margin: 0;
    font-size: 1.42rem;
    line-height: 1.2;
}

.nursery-tag {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.06);
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.nursery-excerpt {
    margin: 0 0 18px;
    font-size: 0.98rem;
    line-height: 1.62;
}

.nursery-button {
    align-self: flex-start;
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 18px;
    border-radius: 999px;
    background: var(--bg-dark, #2f3a2f);
    color: #fff !important;
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.nursery-button:hover,
.nursery-button:focus {
    opacity: 0.9;
    transform: translateY(-1px);
    text-decoration: none;
}

.nursery-empty {
    padding: 24px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.07);
    font-weight: 700;
}

@media (max-width: 980px) {
    .nursery-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .nursery-page {
        padding: 0 12px;
    }

    .nursery-hero {
        padding: 22px;
        border-radius: 18px;
    }

    .nursery-card {
        grid-template-columns: 1fr;
        padding: 18px;
    }

    .nursery-card-logo-wrap {
        min-height: 120px;
    }

    .nursery-card-headline {
        display: block;
    }

    .nursery-tag {
        margin-top: 8px;
    }
}

/* Nursery detail page */
.nursery-detail-page {
    max-width: 1180px;
    margin: 0 auto 56px;
    padding: 0 18px;
}

.nursery-detail-hero {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 28px;
    margin: 28px 0 28px;
    padding: 28px;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.08);
}

.nursery-detail-logo-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.035);
    overflow: hidden;
}

.nursery-detail-logo {
    display: block;
    max-width: 100%;
    max-height: 220px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.nursery-detail-logo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 112px;
    height: 112px;
    border-radius: 999px;
    background: var(--bg-dark, #2f3a2f);
    color: #fff;
    font-size: 3.2rem;
    font-weight: 700;
    line-height: 1;
}

.nursery-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: inherit;
    font-weight: 700;
    text-decoration: none;
    opacity: 0.78;
}

.nursery-back-link:hover,
.nursery-back-link:focus {
    opacity: 1;
    text-decoration: none;
}

.nursery-detail-copy h1 {
    margin: 0 0 8px;
    font-size: clamp(2.1rem, 4vw, 3.5rem);
    line-height: 1.04;
}

.nursery-detail-tag {
    margin: 0 0 18px;
    font-size: 0.95rem;
    opacity: 0.72;
}

.nursery-detail-description {
    max-width: 820px;
    font-size: 1.03rem;
    line-height: 1.7;
}

.nursery-detail-description p:first-child {
    margin-top: 0;
}

.nursery-detail-description p:last-child {
    margin-bottom: 0;
}

.nursery-products-section {
    margin-top: 26px;
}

.nursery-section-headline {
    margin: 0 0 18px;
}

.nursery-section-headline h2 {
    margin: 0;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    line-height: 1.12;
}

.nursery-product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.nursery-product-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.nursery-product-image-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.nursery-product-image-frame {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1 / 1;
    margin: 18px 18px 10px;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.035);
    overflow: hidden;
}

.nursery-product-image-frame img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nursery-product-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    padding: 0 18px 18px;
}

.nursery-product-title {
    margin: 4px 0 10px;
    font-size: 1.08rem;
    line-height: 1.25;
}

.nursery-product-title a {
    color: inherit;
    text-decoration: none;
}

.nursery-product-title a:hover,
.nursery-product-title a:focus {
    text-decoration: underline;
}

.nursery-product-badge {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 10px;
    padding: 5px 11px;
    border-radius: 999px;
    border: 1px solid rgba(37, 157, 75, 0.32);
    background: rgba(37, 157, 75, 0.10);
    color: #25743d;
    font-size: 0.86rem;
    font-weight: 700;
}

.nursery-product-excerpt {
    margin: 0 0 14px;
    font-size: 0.94rem;
    line-height: 1.48;
}

.nursery-product-price {
    margin-top: auto;
    text-align: center;
    font-size: 1.18rem;
    line-height: 1.25;
    font-weight: 800;
}

.nursery-product-shipping,
.nursery-product-delivery {
    text-align: center;
    font-size: 0.86rem;
    line-height: 1.45;
    opacity: 0.62;
}

.nursery-product-shipping {
    margin-top: 6px;
}

.nursery-product-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 44px;
    margin-top: 14px;
    padding: 0 14px;
    border-radius: 999px;
    background: var(--bg-dark, #000080);
    color: #fff !important;
    font-weight: 800;
    text-decoration: none;
}

.nursery-product-button:hover,
.nursery-product-button:focus {
    opacity: 0.92;
    text-decoration: none;
}

@media (max-width: 1120px) {
    .nursery-product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 860px) {
    .nursery-detail-hero {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 560px) {
    .nursery-detail-page {
        padding: 0 12px;
    }

    .nursery-detail-hero {
        padding: 20px;
        border-radius: 20px;
    }

    .nursery-product-grid {
        grid-template-columns: 1fr;
    }
}

/* Detail grid hardening: keep content in the shop grid instead of falling back to full viewport width. */
.page-nursery-detail .nursery-detail-page {
    width: min(1180px, calc(100% - 32px));
    max-width: 1180px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
}

.page-nursery-detail .nursery-detail-hero {
    width: 100%;
    box-sizing: border-box;
}

.page-nursery-detail .nursery-detail-logo {
    max-width: 100%;
    max-height: 220px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.page-nursery-detail .nursery-products-section {
    width: 100%;
}

@media (max-width: 620px) {
    .page-nursery-detail .nursery-detail-page {
        width: min(100% - 24px, 1180px);
    }
}

/* Infinite product loader */
.nursery-loadmore-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin: 28px 0 0;
}

.nursery-loadmore-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 22px;
    border: 0;
    border-radius: 999px;
    background: var(--bg-dark, #000080);
    color: #fff;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.nursery-loadmore-button:hover,
.nursery-loadmore-button:focus {
    opacity: 0.92;
    transform: translateY(-1px);
}

.nursery-loadmore-button:disabled {
    cursor: wait;
    opacity: 0.72;
    transform: none;
}

.nursery-loadmore-button.is-loading::after {
    content: '';
    width: 14px;
    height: 14px;
    margin-left: 10px;
    border: 2px solid rgba(255, 255, 255, 0.55);
    border-top-color: #fff;
    border-radius: 999px;
    animation: nurseryLoaderSpin 0.75s linear infinite;
}

.nursery-loadmore-status {
    min-height: 22px;
    font-size: 0.92rem;
    opacity: 0.72;
    text-align: center;
}

.nursery-loadmore-sentinel {
    width: 100%;
    height: 1px;
}

@keyframes nurseryLoaderSpin {
    to {
        transform: rotate(360deg);
    }
}
