/* ============================================================
   Home AI diagnosis showcase — reference-led redesign (local)
   ============================================================ */
html.diag-enabled .hero .hero-interactive-wrapper:has(.home-diag-showcase) {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
}

.home-diag-showcase {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(245px, 270px);
    grid-template-rows: auto auto auto;
    column-gap: 18px;
    width: min(100%, 760px);
    padding: 27px;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 22px;
    background:
        radial-gradient(circle at 78% 4%, rgba(255, 255, 255, .76), transparent 38%),
        linear-gradient(145deg, rgba(255, 252, 244, .76), rgba(248, 241, 226, .56));
    box-shadow: 0 28px 70px rgba(52, 42, 27, .15), inset 0 1px 0 rgba(255, 255, 255, .78);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #171717;
    isolation: isolate;
}

.home-diag-showcase::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background:
        linear-gradient(120deg, transparent 0 60%, rgba(187, 139, 75, .08) 60% 61%, transparent 61% 100%);
    pointer-events: none;
}

.home-diag-showcase__head {
    grid-column: 1;
    grid-row: 1;
    max-width: 520px;
    margin: 0 0 20px;
    padding: 0 44px 0 4px;
}

.home-diag-showcase__kicker {
    display: inline-flex;
    margin-bottom: 8px;
    color: #9a641f;
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .12em;
}

.home-diag-showcase__head h2 {
    margin: 0 0 9px;
    color: #171717;
    font-family: "Noto Serif JP", serif;
    font-size: clamp(1.75rem, 2.5vw, 2.35rem);
    font-weight: 900;
    line-height: 1.35;
    letter-spacing: .02em;
}

.home-diag-showcase__head p {
    max-width: 490px;
    margin: 0;
    color: #4d463d;
    font-size: .78rem;
    font-weight: 500;
    line-height: 1.75;
}

.home-diag-download-callout {
    grid-column: 1 / 3;
    grid-row: 2;
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    margin: 0 0 18px;
    padding: 13px 15px;
    border: 1px solid rgba(142, 91, 28, .20);
    border-radius: 13px;
    background: linear-gradient(100deg, rgba(255, 255, 255, .94), rgba(255, 247, 232, .90));
    box-shadow: 0 12px 28px rgba(91, 63, 27, .10), inset 0 1px 0 #ffffff;
}

.home-diag-download-callout__icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 11px;
    background: #1d1d1b;
    color: #ffffff;
    box-shadow: 0 9px 20px rgba(29, 29, 27, .20);
}

.home-diag-download-callout__icon svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.home-diag-download-callout__copy {
    display: grid;
    min-width: 0;
}

.home-diag-download-callout__copy small {
    margin-bottom: 2px;
    color: #9a641f;
    font-size: .58rem;
    font-weight: 900;
    letter-spacing: .08em;
}

.home-diag-download-callout__copy strong {
    color: #171717;
    font-size: clamp(1rem, 1.65vw, 1.32rem);
    font-weight: 900;
    line-height: 1.35;
    letter-spacing: .01em;
}

.home-diag-download-callout__copy > span {
    margin-top: 3px;
    color: #655d54;
    font-size: .61rem;
    font-weight: 600;
    line-height: 1.5;
}

.home-diag-download-callout__badge {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(165, 107, 38, .25);
    border-radius: 50%;
    background: #fff8eb;
    color: #9a641f;
    font-size: .68rem;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(117, 76, 28, .10);
}

.home-diag-showcase__body {
    display: contents;
}

.hero .home-diag-showcase .home-diag-card {
    position: relative !important;
    grid-column: 1 / 3 !important;
    grid-row: 3 !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 22px 20px 17px !important;
    border: 1px solid rgba(77, 58, 32, .10) !important;
    border-radius: 16px !important;
    background: rgba(255, 255, 255, .88) !important;
    box-shadow: 0 18px 42px rgba(54, 42, 25, .13), inset 0 1px 0 #ffffff !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    overflow: visible !important;
}

.hero .home-diag-showcase .home-diag-card::before {
    display: none !important;
}

.hero .home-diag-showcase .diag-card__dismiss {
    top: 13px !important;
    right: 13px !important;
    width: 32px !important;
    height: 32px !important;
    background: rgba(255, 255, 255, .80) !important;
    color: #24211d !important;
    box-shadow: 0 8px 22px rgba(55, 42, 24, .11) !important;
}

.hero .home-diag-showcase .diag-card__eyebrow {
    display: flex !important;
    align-items: center !important;
    gap: 9px !important;
    margin: 0 0 11px !important;
    color: #1d1b18 !important;
    font-family: "Noto Serif JP", serif !important;
    font-size: 1.32rem !important;
    font-weight: 900 !important;
    line-height: 1.3 !important;
}

.hero .home-diag-showcase .diag-card__eyebrow small {
    font-family: "Noto Sans JP", sans-serif;
    font-size: .75rem;
    font-weight: 800;
}

.hero .home-diag-showcase .diag-card__eyebrow::before {
    width: 35px !important;
    height: 35px !important;
}

.hero .home-diag-showcase .diag-card__sub {
    margin: 0 0 17px !important;
    color: #49423a !important;
    font-size: .8rem !important;
    font-weight: 600 !important;
    line-height: 1.7 !important;
    text-align: left !important;
}

.hero .home-diag-showcase .diag-card__features {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 0 !important;
    margin: 0 0 17px !important;
}

.hero .home-diag-showcase .diag-card__feature {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    min-width: 0 !important;
    min-height: 0 !important;
    gap: 7px !important;
    padding: 2px 7px !important;
    border: 0 !important;
    border-left: 1px solid rgba(82, 65, 41, .12) !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: center !important;
}

.hero .home-diag-showcase .diag-card__feature:first-child {
    border-left: 0 !important;
}

.hero .home-diag-showcase .diag-card__feature-ico {
    display: grid !important;
    place-items: center !important;
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    background: #fffaf1 !important;
    color: #af762e !important;
    box-shadow: 0 6px 16px rgba(124, 84, 32, .10) !important;
}

.hero .home-diag-showcase .diag-card__feature-ico svg {
    width: 26px;
    height: 26px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hero .home-diag-showcase .diag-card__feature-copy {
    display: grid !important;
    gap: 3px !important;
    justify-items: center !important;
}

.hero .home-diag-showcase .diag-card__feature-title {
    color: #28231d !important;
    font-size: .78rem !important;
    font-weight: 800 !important;
    line-height: 1.35 !important;
}

.hero .home-diag-showcase .diag-card__feature-sub {
    color: #625a51 !important;
    font-size: .64rem !important;
    font-weight: 600 !important;
    line-height: 1.45 !important;
}

.hero .home-diag-showcase .diag-card__btn {
    min-height: 48px !important;
    padding: 12px 16px !important;
    border: 1px solid #171717 !important;
    border-radius: 8px !important;
    background: #171717 !important;
    color: #ffffff !important;
    box-shadow: 0 12px 24px rgba(21, 18, 15, .20) !important;
    font-size: .9rem !important;
    font-weight: 800 !important;
    letter-spacing: .04em !important;
}

.hero .home-diag-showcase .diag-card__btn:hover {
    background: #000000 !important;
    transform: translateY(-1px) !important;
}

.hero .home-diag-showcase .diag-card__note {
    margin: 9px 0 0 !important;
    color: #665e55 !important;
    font-size: .68rem !important;
    font-weight: 600 !important;
}

.hero .home-diag-showcase .diag-card__restart {
    margin-top: 11px !important;
    padding: 7px !important;
    color: #5f574f !important;
    font-size: .76rem !important;
    font-weight: 700 !important;
}

.home-diag-report {
    position: relative;
    grid-column: 2;
    grid-row: 1;
    align-self: start;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-width: 0;
    padding-top: 58px;
    transform: translate(4px, -64px) scale(1.2);
    transform-origin: top right;
}

.home-diag-report__badge {
    position: absolute;
    top: 43px;
    right: -4px;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #222321;
    color: #ffffff;
    font-size: .58rem;
    font-weight: 800;
    line-height: 1.45;
    text-align: center;
    box-shadow: 0 12px 28px rgba(26, 24, 20, .22);
}

.home-diag-report__paper {
    position: relative;
    z-index: 1;
    margin: 0 6px 13px 0;
    padding: 5px;
    border: 1px solid rgba(76, 58, 34, .14);
    background: #ffffff;
    box-shadow: 0 16px 34px rgba(56, 42, 24, .20);
}

.home-diag-report__paper::before,
.home-diag-report__paper::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border: 1px solid rgba(76, 58, 34, .10);
    background: #fffefb;
}

.home-diag-report__paper::before {
    transform: translate(-7px, 6px);
}

.home-diag-report__paper::after {
    transform: translate(-13px, 12px);
}

.home-diag-report__paper img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

@media (min-width: 1241px) {
    html.diag-enabled .hero .hero-grid {
        grid-template-columns: minmax(360px, .78fr) minmax(620px, 1.22fr) !important;
        gap: 42px !important;
    }

    html.diag-enabled .hero .hero-copy h1 {
        max-width: 100% !important;
        font-size: clamp(2.65rem, 3.1vw, 3rem) !important;
        line-height: 1.28 !important;
        letter-spacing: -.035em !important;
    }

    html.diag-enabled .hero .hero-interactive-wrapper:has(.home-diag-showcase) {
        height: auto !important;
        min-height: 0 !important;
    }
}

@media (min-width: 981px) and (max-width: 1240px) {
    html.diag-enabled .hero .hero-grid {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 42px !important;
    }

    html.diag-enabled .hero .hero-copy {
        width: min(100%, 760px) !important;
        max-width: 760px !important;
    }

    html.diag-enabled .hero .hero-interactive-wrapper:has(.home-diag-showcase) {
        height: auto !important;
        min-height: 0 !important;
    }

    .home-diag-showcase {
        width: min(100%, 760px);
        margin-inline: auto;
    }
}

@media (min-width: 981px) {
    html.diag-enabled .hero .hero-copy h1 {
        position: relative;
        top: -28px;
        margin-bottom: 14px;
    }
}

@media (max-width: 980px) {
    .home-diag-showcase {
        width: min(100%, 820px);
        margin-inline: auto;
    }
}

@media (max-width: 640px) {
    html.diag-enabled .hero .hero-copy h1,
    html.diag-enabled .hero .hero-copy .hero-sub-keywords,
    html.diag-enabled .hero .hero-copy .hero-lead,
    html.diag-enabled .hero .hero-copy .hero-lead span {
        color: #111111 !important;
        opacity: 1 !important;
        text-shadow: none !important;
    }

    .home-diag-showcase {
        display: block;
        width: calc(100% - 8px);
        padding: 22px 17px 18px;
        border-radius: 18px;
    }

    .home-diag-showcase__head {
        margin-bottom: 17px;
        padding-right: 38px;
    }

    .home-diag-showcase__head h2 {
        font-size: clamp(1.55rem, 7.2vw, 2rem);
        line-height: 1.4;
    }

    .home-diag-showcase__head p {
        font-size: .7rem;
    }

    .home-diag-download-callout {
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 10px;
        padding: 12px;
    }

    .home-diag-download-callout__icon {
        width: 40px;
        height: 40px;
    }

    .home-diag-download-callout__copy strong {
        font-size: clamp(.9rem, 4.1vw, 1.08rem);
    }

    .home-diag-download-callout__copy > span {
        font-size: .56rem;
    }

    .home-diag-download-callout__badge {
        display: none;
    }

    .home-diag-showcase__body {
        display: grid;
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .hero .home-diag-showcase .home-diag-card {
        grid-column: 1 !important;
        grid-row: auto !important;
        width: 100% !important;
        max-width: none !important;
        padding: 20px 15px 15px !important;
    }

    .hero .home-diag-showcase .diag-card__eyebrow {
        font-size: 1.16rem !important;
    }

    .hero .home-diag-showcase .diag-card__sub {
        font-size: .75rem !important;
    }

    .hero .home-diag-showcase .diag-card__features {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 12px 0 !important;
    }

    .hero .home-diag-showcase .diag-card__feature:nth-child(3) {
        border-left: 0 !important;
    }

    .hero .home-diag-showcase .diag-card__feature-title {
        font-size: .74rem !important;
    }

    .hero .home-diag-showcase .diag-card__feature-sub {
        font-size: .62rem !important;
    }

    .hero .home-diag-showcase .diag-card__btn {
        width: 100% !important;
        min-height: 50px !important;
        padding-inline: 14px !important;
        font-size: .84rem !important;
    }

    .home-diag-report {
        display: none !important;
    }

}

@media (max-width: 390px) {
    .home-diag-showcase {
        width: 100%;
        padding-inline: 13px;
    }

    .home-diag-showcase__head h2 br {
        display: none;
    }

}
