/*
Theme Name: Shinkazoku Kaigi D Canonical Front
Description: Local-only canonical D mock implementation for GeneratePress.
Author: Shinkazoku Kaigi
Template: generatepress
Version: 1.0.19
Text Domain: shinkazokukaigi-d-staging-child
*/

/*
 * GeneratePress stores layout settings per site. Keep the approved full-width
 * page adapters independent from those Customizer defaults.
 */
body.skd-adapter-page #page.site.grid-container,
body.skd-adapter-page #content.site-content,
body.skd-adapter-page #primary.content-area,
body.skd-adapter-page #main.site-main,
body.skd-adapter-page article.inside-article,
body.skd-adapter-page .entry-content {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}

/*
 * The seven hubs use the exact same header component as the front page.
 * Suppress the unrelated legacy GeneratePress branding and navigation only
 * after the shared replacement has been emitted for an approved hub slug.
 */
body.skd-adapter-page.skd-shared-site-header > .site-header,
body.skd-adapter-page.skd-shared-site-header #masthead {
    display: none !important;
}

body.skd-adapter-page .skd-d--shared-head {
    width: 100%;
    background: #f4efe7;
}

body.skd-adapter-page .skd-d--shared-head .skd-d__shell--head {
    box-shadow: 0 0 42px rgb(61 72 62 / 8%);
}

body.skd-adapter-page #content.site-content {
    display: block;
}

body.skd-adapter-page #left-sidebar,
body.skd-adapter-page #right-sidebar {
    display: none;
}

body.skd-adapter-page .sk-wordpress-adapter {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
}

/*
 * Seven-hub first view, v1.
 * Keep the established site header and page title, then align the approved
 * illustration with the intro copy in the same warm visual language as home.
 */
body.skd-adapter-page .entry-header {
    margin: 0;
    padding: clamp(24px, 4vw, 42px) max(16px, calc((100% - 1080px) / 2)) 10px;
    background: #fcf5e7;
}

body.skd-adapter-page .entry-header .entry-title {
    width: min(100%, 1080px);
    margin: 0 auto;
    color: #342c27;
    font-size: clamp(1.85rem, 5vw, 3rem);
    font-weight: 800;
    line-height: 1.35;
    letter-spacing: .01em;
}

body.skd-adapter-page .entry-content > .sk-update-date {
    width: 100%;
    max-width: none;
    margin: 0 !important;
    padding: 0 max(16px, calc((100% - 1080px) / 2)) 18px !important;
    color: #6a5d54 !important;
    border-left: 0 !important;
    background: #fcf5e7;
    font-size: .875rem;
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 20px max(16px, calc((100% - 1080px) / 2)) 34px;
    background: linear-gradient(180deg, #fcf5e7 0%, #fffaf4 100%);
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro > .eyebrow {
    order: 0;
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro > .page-illustration {
    order: 1;
    width: 100%;
    max-width: 720px;
    margin: 12px auto 22px;
    padding: 9px;
    border: 1px solid #e8cabb;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 30px rgb(76 53 39 / 10%);
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro > p:not(.eyebrow) {
    order: 2;
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro > .page-illustration img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 430px;
    aspect-ratio: auto;
    object-fit: contain;
    border-radius: 12px;
}

body.skd-adapter-page .sk-wordpress-adapter .page-intro > .page-illustration figcaption {
    display: none;
}

/* Emergency guidance must remain the first readable item in its intro. */
body.skd-adapter-page .sk-emergency-support .page-intro > .urgent-message {
    order: 1;
}

body.skd-adapter-page .sk-emergency-support .page-intro > .page-illustration {
    order: 2;
}

body.skd-adapter-page .sk-emergency-support .page-intro > p:not(.eyebrow, .urgent-message) {
    order: 3;
}

@media (min-width: 901px) {
    body.skd-adapter-page .sk-wordpress-adapter .page-intro {
        display: grid;
        grid-template-columns: minmax(0, .92fr) minmax(420px, 1.08fr);
        column-gap: clamp(36px, 5vw, 72px);
        align-items: start;
        min-height: 430px;
        padding-top: 34px;
        padding-bottom: 48px;
    }

    body.skd-adapter-page .sk-wordpress-adapter .page-intro > * {
        grid-column: 1;
    }

    body.skd-adapter-page .sk-wordpress-adapter .page-intro > .page-illustration {
        grid-column: 2;
        grid-row: 1 / span 20;
        align-self: center;
        max-width: none;
        margin: 0;
        padding: 12px;
    }
}


/* Task58 local pilot: suppress only the legacy masthead after shared header emission. */
body.skd-public-header-rollout.skd-shared-site-header > .site-header,
body.skd-public-header-rollout.skd-shared-site-header #masthead {
    display: none !important;
}

body.skd-public-header-rollout .skd-d--shared-head {
    width: 100%;
    background: #f4efe7;
}

body.skd-public-header-rollout .skd-d--shared-head .skd-d__shell--head {
    box-shadow: 0 0 42px rgb(61 72 62 / 8%);
}

/* Task59 production QA: hide only GeneratePress's duplicate featured image. */
body.skd-public-header-featured-image-fix .featured-image.page-header-image {
    display: none !important;
}
