/* =========================================================
   Top.css
   「-緋彩乃式- official site」
   Topページ専用スタイル
   ---------------------------------------------------------
   Common.css：
   ・リセット
   ・基本カラー / フォント
   ・共通リンク
   ・共通Header / Side Menu / Footer / Top Button
   ・アクセシビリティ
   ・Reduced Motion

   Top.css：
   ・Topページ固有のレイアウト
   ・First View
   ・Side Menuの外観
   ・メインコンテンツ
   ・最新News / 最新漫画
   ・彼岸花の余韻
   ========================================================= */


/* =========================================================
   Header
   ========================================================= */

/*
 * Headerの基本配置・z-indexはCommon.cssで定義。
 * Top.cssではTopページでの表示状態だけを定義する。
 */

.site-header {
    height: 64px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0 4vw;

    background: rgba(0, 0, 0, 0.88);

    border-bottom:
        1px solid rgba(242, 240, 235, 0.12);

    transform: translateY(-100%);

    transition: none;
}


.site-header.is-visible {
    transform: translateY(0);
}


/* =========================================================
   Side Menu
   ========================================================= */

/* ---------------------------------------------------------
   Side Menu本体
   --------------------------------------------------------- */

/*
 * position / top / right / z-indexはCommon.css。
 */

.side-menu {
    width: 200px;
    min-width: 200px;

    visibility: hidden;
    pointer-events: none;
}


.side-menu.is-open {
    visibility: visible;
    pointer-events: auto;
}


/* ---------------------------------------------------------
   黒い透明帯
   --------------------------------------------------------- */

.side-menu__backdrop {
    width: 100%;
    height: 100%;

    box-sizing: border-box;

    padding: 74px 16px 24px;

    background: rgba(0, 0, 0, 0.82);

    border-left:
        1px solid rgba(242, 240, 235, 0.12);

    overflow-y: auto;
    overflow-x: hidden;
}


/* ---------------------------------------------------------
   Navigation
   --------------------------------------------------------- */

.side-menu__nav {
    width: 100%;
}


.side-menu__list {
    width: 100%;

    margin: 0;
    padding: 0;

    list-style: none;
}


/* ---------------------------------------------------------
   Menu Item
   --------------------------------------------------------- */

.side-menu__item {
    position: relative;

    width: 100%;

    margin: 0;
    padding: 0;
}


.side-menu__item+.side-menu__item {
    margin-top: 8px;
}


/* ---------------------------------------------------------
   木札ボタン
   --------------------------------------------------------- */

.side-menu__trigger {
    position: relative;

    display: block;

    width: 100%;
    height: 48px;

    margin: 0;
    padding: 0;

    background: transparent;

    color: #f2f0eb;

    cursor: pointer;

    font: inherit;
    text-align: center;

    overflow: hidden;
}


/* ---------------------------------------------------------
   木札画像
   --------------------------------------------------------- */

.side-menu__tag {
    position: absolute;

    top: 50%;
    left: 50%;

    width: 120px;
    height: 120px;

    transform:
        translate(-50%, -50%) rotate(90deg) scale(0.78);

    transform-origin: center;

    pointer-events: none;
}


/* ---------------------------------------------------------
   木札上の文字
   --------------------------------------------------------- */

.side-menu__label {
    position: absolute;

    top: 50%;
    left: 50%;

    z-index: 2;

    width: 100%;

    transform:
        translate(-50%, -50%);

    color: #f2f0eb;

    font-family: serif;
    font-size: 0.85rem;
    line-height: 1;

    letter-spacing: 0.14em;

    white-space: nowrap;

    pointer-events: none;
}


/* ---------------------------------------------------------
   木札 Hover
   --------------------------------------------------------- */

.side-menu__trigger:hover .side-menu__tag {
    filter: brightness(1.12);
}


/* ---------------------------------------------------------
   説明表示領域
   --------------------------------------------------------- */

.side-menu__description {
    width: 100%;

    box-sizing: border-box;

    margin: 4px 0 8px;
    padding: 0;
}


/* ---------------------------------------------------------
   仮奉書紙
   --------------------------------------------------------- */

.side-menu__paper {
    width: 100%;

    box-sizing: border-box;

    padding: 18px 16px;

    background: #f2f0eb;

    color: #111;

    border:
        1px solid rgba(242, 240, 235, 0.35);
}


/* ---------------------------------------------------------
   奉書紙上のテキスト
   --------------------------------------------------------- */

.side-menu__paper-content {
    text-align: left;
}


.side-menu__paper-content p {
    margin: 0 0 12px;

    color: #222;

    font-family: serif;
    font-size: 0.72rem;
    line-height: 1.9;

    letter-spacing: 0.06em;
}


.side-menu__paper-content a {
    display: inline-block;

    color: #111;

    font-family: serif;
    font-size: 0.72rem;
    line-height: 1.5;

    letter-spacing: 0.06em;

    text-decoration: none;

    white-space: nowrap;
}


.side-menu__paper-content a:hover,
.side-menu__paper-content a:focus-visible {
    text-decoration: underline;
}


/* =========================================================
   First View
   ========================================================= */

.first-view {
    position: relative;

    min-height: 210svh;

    overflow: hidden;
    isolation: isolate;

    background: #000;

    color: #f2f0eb;
}


/* ---------------------------------------------------------
   First View Background
   --------------------------------------------------------- */

.first-view__background {
    position: absolute;

    inset: 0;

    overflow: hidden;

    pointer-events: none;

    z-index: -1;
}


/* ---------------------------------------------------------
   Red Ink
   --------------------------------------------------------- */

.first-view__ink {
    position: absolute;

    width: 170%;
    height: 170%;

    max-width: none;

    object-fit: cover;

    pointer-events: none;

    transform-origin: center center;
}


/* Ink A */

.first-view__ink--a {
    top: -32%;
    left: -35%;

    opacity: 0.20;

    animation:
        first-view-ink-a 28s ease-in-out infinite alternate;
}


/* Ink B */

.first-view__ink--b {
    top: -25%;
    left: -5%;

    opacity: 0.15;

    animation:
        first-view-ink-b 36s ease-in-out infinite alternate;
}


/* Ink C */

.first-view__ink--c {
    top: -10%;
    right: -38%;

    opacity: 0.14;

    animation:
        first-view-ink-c 32s ease-in-out infinite alternate;
}


/* ---------------------------------------------------------
   Gold Powder
   --------------------------------------------------------- */

.first-view__gold {
    position: absolute;

    width: 42%;
    max-width: 720px;
    min-width: 360px;

    top: 10%;
    right: 12%;

    opacity: 0.20;

    pointer-events: none;
}


/* ---------------------------------------------------------
   Higanbana
   --------------------------------------------------------- */

.first-view__higanbana {
    position: absolute;

    width: min(30vw, 460px);
    min-width: 260px;

    right: 8%;
    bottom: 2%;

    opacity: 0.68;

    pointer-events: none;
}


/* ---------------------------------------------------------
   First View Content
   --------------------------------------------------------- */

.first-view__content {
    position: relative;

    min-height: 210svh;

    z-index: 1;
}


/* =========================================================
   First View 仮一枚絵
   ========================================================= */

.first-view__visual {
    position: absolute;

    top: 18%;
    left: 8%;

    width: min(28vw, 420px);

    opacity: 0;

    z-index: 2;

    pointer-events: none;

    animation:
        first-view-visual-fade 2.4s ease-out forwards;
}


.first-view__visual img {
    width: 100%;
    height: auto;
}


@keyframes first-view-visual-fade {

    from {
        opacity: 0;
    }

    to {
        opacity: 0.72;
    }

}


/* =========================================================
   First View Title
   ========================================================= */

.first-view__title {
    position: absolute;

    top: 12%;
    right: 22%;

    display: flex;
    flex-direction: column;
    align-items: center;

    margin: 0;

    font-family: serif;
    font-size: clamp(2.8rem, 5vw, 5rem);
    font-weight: 500;

    line-height: 1.15;

    letter-spacing: 0.08em;

    color: #f2f0eb;
}


/* =========================================================
   First View Copy
   ========================================================= */

.first-view__copy {
    position: absolute;

    top: 145svh;
    left: 22%;

    width: min(56vw, 720px);
    max-width: 720px;
}


.first-view__lead {
    margin: 0 0 2.5rem;

    font-family: serif;
    font-size: clamp(1.25rem, 2vw, 2rem);

    line-height: 1.8;

    letter-spacing: 0.12em;

    color: #f2f0eb;
}


.first-view__text {
    margin: 0;

    font-family: serif;
    font-size: clamp(0.85rem, 1.2vw, 1.05rem);

    line-height: 2.4;

    letter-spacing: 0.12em;

    color: rgba(242, 240, 235, 0.78);
}


/* =========================================================
   Main Content
   ========================================================= */

.content-section {
    position: relative;

    min-height: 55svh;

    display: flex;
    align-items: center;

    padding: 8rem 10vw;

    background: #080808;

    color: #f2f0eb;

    overflow: hidden;
}


/* ---------------------------------------------------------
   各項目の配置
   --------------------------------------------------------- */

.content-section--record {
    justify-content: flex-start;
}


.content-section--retrospect {
    justify-content: flex-end;
}


.content-section--gallery {
    justify-content: flex-start;
}


/* ---------------------------------------------------------
   Content Panel
   --------------------------------------------------------- */

.content-panel {
    position: relative;

    width: min(760px, 100%);

    color: #f2f0eb;
}


.content-panel__base {
    position: relative;

    display: flex;
    align-items: flex-start;

    gap: clamp(2rem, 5vw, 5rem);

    padding: 2rem 0;
}


/* ---------------------------------------------------------
   項目タイトル
   --------------------------------------------------------- */

.content-panel__trigger {
    position: relative;

    flex: 0 0 auto;

    min-width: 180px;

    padding: 0.8rem 1.8rem;

    border:
        1px solid rgba(242, 240, 235, 0.45);

    border-radius: 999px;

    background: transparent;

    color: #f2f0eb;

    font-family: serif;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 500;

    line-height: 1.2;

    letter-spacing: 0.16em;

    cursor: pointer;

    transition:
        background-color 0.45s ease,
        color 0.45s ease,
        border-color 0.45s ease;
}


.content-panel__title {
    display: block;

    white-space: nowrap;
}


/* ---------------------------------------------------------
   説明ブロック
   --------------------------------------------------------- */

.content-panel__info {
    flex: 1 1 auto;

    min-width: 0;

    padding-top: 0.45rem;

    opacity: 0;

    transform: translateX(-12px);

    pointer-events: none;

    transition:
        opacity 0.6s ease,
        transform 0.6s ease;
}


/* ---------------------------------------------------------
   PC：Hover
   --------------------------------------------------------- */

@media (hover: hover) and (pointer: fine) {

    .content-panel:hover .content-panel__info {
        opacity: 1;

        transform: translateX(0);

        pointer-events: auto;
    }


    .content-section--record .content-panel:hover .content-panel__trigger {
        background: #8b3f68;
        border-color: #8b3f68;

        color: #f7f2f4;
    }


    .content-section--retrospect .content-panel:hover .content-panel__trigger {
        background: #4f858c;
        border-color: #4f858c;

        color: #f3f7f7;
    }


    .content-section--gallery .content-panel:hover .content-panel__trigger {
        background: #b08b43;
        border-color: #b08b43;

        color: #17130b;
    }

}


/* ---------------------------------------------------------
   説明文
   --------------------------------------------------------- */

.content-panel__description {
    margin: 0 0 1.2rem;

    color: rgba(242, 240, 235, 0.78);

    font-family: serif;

    font-size: clamp(0.82rem, 1.1vw, 1rem);

    line-height: 2.2;

    letter-spacing: 0.08em;
}


/* ---------------------------------------------------------
   Hyperlink
   --------------------------------------------------------- */

.content-panel__link {
    display: inline-block;

    color: #f2f0eb;

    font-family: serif;

    font-size: 0.85rem;

    line-height: 1.5;

    letter-spacing: 0.12em;

    text-decoration: none;

    transition: opacity 0.3s ease;
}


.content-panel__link:hover,
.content-panel__link:focus-visible {
    opacity: 0.65;
}


/* ---------------------------------------------------------
   項目ごとのアクセント
   --------------------------------------------------------- */

.content-section--record .content-panel__trigger {
    border-color: rgba(150, 65, 105, 0.65);
}


.content-section--retrospect .content-panel__trigger {
    border-color: rgba(75, 135, 145, 0.65);
}


.content-section--gallery .content-panel__trigger {
    border-color: rgba(181, 145, 72, 0.7);
}


/* =========================================================
   Latest
   ========================================================= */

.latest {
    min-height: 75svh;

    display: grid;

    grid-template-columns:
        minmax(0, 1.15fr) minmax(0, 0.85fr);

    gap: clamp(2rem, 5vw, 6rem);

    padding: 8rem 12vw;

    background: #050505;

    color: #f2f0eb;
}


/* ---------------------------------------------------------
   Common Heading
   --------------------------------------------------------- */

.latest__heading {
    margin-bottom: 3rem;

    padding-bottom: 1.25rem;

    border-bottom:
        1px solid rgba(242, 240, 235, 0.25);
}


.latest__label {
    display: block;

    margin-bottom: 0.75rem;

    font-size: 0.7rem;

    letter-spacing: 0.25em;

    opacity: 0.55;
}


.latest h2 {
    margin: 0;

    font-family: serif;

    font-size: clamp(1.8rem, 3vw, 2.8rem);

    font-weight: 500;

    letter-spacing: 0.12em;
}
    

/* =========================================================
   Latest News
   ========================================================= */

.latest-news {
    padding: 3rem 0;
}


.latest-news__list {
    margin: 0;
    padding: 0;

    list-style: none;
}


.latest-news__list li {
    display: grid;

    grid-template-columns: 110px 1fr;

    gap: 1.5rem;

    padding: 1.25rem 0;

    border-bottom:
        1px solid rgba(242, 240, 235, 0.12);
}


.latest-news__list time {
    font-size: 0.75rem;

    letter-spacing: 0.08em;

    opacity: 0.5;
}


.latest-news__list a {
    color: #f2f0eb;

    line-height: 1.8;

    text-decoration: none;
}


.latest-news__list a:hover,
.latest-news__list a:focus-visible {
    text-decoration: underline;
}


/* =========================================================
   Latest Manga
   ========================================================= */

.latest-manga {
    position: relative;

    padding: 3rem;

    border:
        1px solid rgba(242, 240, 235, 0.2);

    background: rgba(255, 255, 255, 0.02);
}


.latest-manga__item {
    padding: 1rem 0 2rem;
}


.latest-manga__number {
    display: block;

    margin-bottom: 1.25rem;

    font-size: 0.7rem;

    letter-spacing: 0.2em;

    opacity: 0.5;
}


.latest-manga__item>a {
    display: block;

    margin-bottom: 1rem;

    color: #f2f0eb;

    font-family: serif;

    font-size: 1.5rem;

    letter-spacing: 0.1em;

    text-decoration: none;
}


.latest-manga__item p {
    margin: 0;

    color: rgba(242, 240, 235, 0.65);

    line-height: 2;
}


/* ---------------------------------------------------------
   More Link
   --------------------------------------------------------- */

.latest__more {
    display: inline-block;

    margin-top: 2rem;

    color: #f2f0eb;

    font-size: 0.8rem;

    letter-spacing: 0.12em;

    text-decoration: none;
}


.latest__more:hover,
.latest__more:focus-visible {
    text-decoration: underline;
}


/* =========================================================
   Afterglow
   ========================================================= */

.afterglow {
    position: relative;

    min-height: 45svh;

    display: flex;
    align-items: flex-end;
    justify-content: center;

    gap: clamp(1rem, 4vw, 5rem);

    overflow: hidden;

    padding: 0 5vw;

    background: #000;
}


.afterglow img {
    flex: 0 0 auto;

    width: clamp(180px, 22vw, 360px);

    height: auto;

    opacity: 0.75;

    transform-origin: bottom center;
}


.afterglow img:nth-child(1) {
    transform:
        translateY(15%) scale(0.85);
}


.afterglow img:nth-child(2) {
    transform:
        translateY(5%) scale(1);
}


.afterglow img:nth-child(3) {
    transform:
        translateY(-3%) scale(1.08);
}


.afterglow img:nth-child(4) {
    transform:
        translateY(8%) scale(0.92);
}


.afterglow img:nth-child(5) {
    transform:
        translateY(18%) scale(0.78);
}


/* =========================================================
   Footer
   ========================================================= */

/*
 * Footerのposition / width / 基本padding / text-alignは
 * Common.cssで定義。
 *
 * Topページでは背景と境界線のみ指定する。
 */

.site-footer {
    min-height: 180px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 3rem;

    background: #000;

    border-top:
        1px solid rgba(242, 240, 235, 0.1);

    color: rgba(242, 240, 235, 0.6);

    font-size: 0.8rem;

    letter-spacing: 0.08em;
}


/* =========================================================
   Top Button
   ========================================================= */

/*
 * position / z-index / 基本配置はCommon.css。
 * 表示状態だけTop.jsと連携する。
 */

.top-button {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    border:
        1px solid rgba(242, 240, 235, 0.35);

    background: rgba(0, 0, 0, 0.9);

    color: #f2f0eb;

    font-size: 1.2rem;

    text-decoration: none;
}


.top-button.is-visible {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}


/* =========================================================
   Smartphone
   ========================================================= */

@media (max-width: 768px) {

    /* -----------------------------------------------------
       Main Content
       ----------------------------------------------------- */

    .content-section {
        min-height: 60svh;

        justify-content: flex-start;

        padding: 6rem 8vw;
    }


    .content-section--retrospect {
        justify-content: flex-start;
    }


    .content-panel {
        width: 100%;
    }


    .content-panel__base {
        display: block;

        padding: 1rem 0;
    }


    .content-panel__trigger {
        min-width: 0;

        padding: 0.75rem 1.5rem;

        font-size: 1.7rem;
    }


    .content-panel__info {
        padding-top: 1.8rem;

        transform: translateY(-8px);
    }


    /*
     * タッチ端末ではJSのis-openで表示。
     */

    .content-panel.is-open .content-panel__info {
        opacity: 1;

        transform: translateY(0);

        pointer-events: auto;
    }


    /*
     * タッチ端末では開いた項目の色を反転。
     */

    .content-section--record .content-panel.is-open .content-panel__trigger {
        background: #8b3f68;
        border-color: #8b3f68;

        color: #f7f2f4;
    }


    .content-section--retrospect .content-panel.is-open .content-panel__trigger {
        background: #4f858c;
        border-color: #4f858c;

        color: #f3f7f7;
    }


    .content-section--gallery .content-panel.is-open .content-panel__trigger {
        background: #b08b43;
        border-color: #b08b43;

        color: #17130b;
    }


    /* -----------------------------------------------------
       Latest
       ----------------------------------------------------- */

    .latest {
        grid-template-columns: 1fr;

        padding: 6rem 8vw;
    }


    .latest-news__list li {
        grid-template-columns: 1fr;

        gap: 0.4rem;
    }


    .latest-manga {
        padding: 2rem;
    }

}


/* =========================================================
   Reduced Motion
   ========================================================= */

/*
 * 基本的なanimation / transition停止はCommon.cssが担当。
 * ここではFirst View固有の初期表示値のみ補正する。
 */

@media (prefers-reduced-motion: reduce) {

    .first-view__visual {
        opacity: 0.72;

        animation: none;
    }


    .first-view__ink--a,
    .first-view__ink--b,
    .first-view__ink--c {
        animation: none;
    }

}