/* =====================================
   RENA SAITO
   FLOATING LAYOUT
   Shared styles
===================================== */

@view-transition {
    navigation: auto;
}

::view-transition-group(brand-lockup) {
    z-index: 999;
    animation-duration: 1.7s;
    animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

::view-transition-old(brand-lockup),
::view-transition-new(brand-lockup) {
    animation-duration: 1.7s;
    animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    mix-blend-mode: normal;
}

@keyframes floatingPageFadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

@keyframes floatingPageFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

::view-transition-old(root) {
    animation: floatingPageFadeOut 0.58s ease both;
}

::view-transition-new(root) {
    animation: floatingPageFadeIn 0.65s ease both;
}


/* =====================================
   FONT
===================================== */

@font-face {
    font-family: "Akzidenz Super";
    src: url("../fonts/AkzidenzGroteskBQ-Super.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: block;
}

@font-face {
    font-family: "Akzidenz Bold";
    src: url("../fonts/AkzidenzGroteskBQ-Bold.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: block;
}


@font-face {
    font-family: "Adobe Caslon";
    src: url("../fonts/ACaslonPro-Regular.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}


/* =====================================
   RESET / SHARED PAGE SHELL
===================================== */

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    background: #fff;
    color: #111;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

* {
    box-sizing: border-box;
}

body.floating-page {
    min-height: 100vh;
}

.site-page {
    position: relative;
    min-height: 100vh;
    padding: 48px 7vw 150px;
}

.site-header {
    text-align: center;
    margin-bottom: 105px;
}

.site-brand {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    view-transition-name: brand-lockup;
}

html.no-brand-transition .site-brand {
    view-transition-name: none;
}

.site-logo {
    margin: 0;
    line-height: 0;
}

.site-logo a {
    display: block;
    text-decoration: none;
    transition: opacity 0.25s ease;
}

.site-logo a:hover {
    opacity: 0.45;
}

.site-logo-image {
    display: block;
    width: auto;
    height: 48px;
    margin: 0;
    padding: 0;
    filter: none;
}

.site-role {
    margin-top: 15px;
    font-family: "Akzidenz Bold", sans-serif;
    font-size: 22px;
    font-weight: 400;
    line-height: 1.06;
    letter-spacing: -0.06em;
    white-space: nowrap;
    color: #262626;
}


/* =====================================
   EDGE NAV
===================================== */

.site-edge-nav {
    position: fixed;
    top: 50%;
    z-index: 30;
    font-family: "Akzidenz Bold", sans-serif;
    font-size: 16px;
    font-weight: 400;
    letter-spacing: -0.02em;
    line-height: 1;
    color: #000;
    text-decoration: none;
    writing-mode: vertical-rl;
    opacity: 1;
    transition: opacity 0.25s ease;
    will-change: opacity;
}

.site-edge-nav:hover {
    opacity: 0.45;
}

.site-edge-left {
    left: 26px;
    transform: translateY(-50%);
}

.site-edge-right {
    right: 26px;
    transform: translateY(-50%) rotate(180deg);
}

.site-instagram {
    position: absolute;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%);
    font-family: "Akzidenz Bold", sans-serif;
    font-size: 12.5px;
    font-weight: 400;
    letter-spacing: 0.02em;
    line-height: 1;
    color: #000;
    text-decoration: none;
    transition: opacity 0.25s ease;
}

.site-instagram:hover {
    opacity: 0.45;
}


/* =====================================
   MENU BUTTON
===================================== */

.menu-button {
    position: fixed;
    top: 26px;
    right: 28px;
    z-index: 120;
    width: 24px;
    height: 14px;
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    background: transparent;
    cursor: pointer;
}

.menu-button span {
    position: absolute;
    left: 0;
    width: 100%;
    height: 1.5px;
    background: #000;
    transform-origin: center;
    transition:
        top 0.3s ease,
        transform 0.3s ease,
        opacity 0.2s ease;
}

.menu-button span:nth-child(1) { top: 0; }
.menu-button span:nth-child(2) { top: 6px; }
.menu-button span:nth-child(3) { top: 12px; }

.menu-button.active span:nth-child(1) {
    top: 6px;
    transform: rotate(45deg);
}

.menu-button.active span:nth-child(2) {
    opacity: 0;
}

.menu-button.active span:nth-child(3) {
    top: 6px;
    transform: rotate(-45deg);
}


/* =====================================
   MENU OVERLAY
===================================== */

.menu-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.97);
    opacity: 0;
    visibility: hidden;
    transition:
        opacity 0.35s ease,
        visibility 0.35s ease;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.menu-inner {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
    text-align: center;
}

.menu-main {
    font-family: "Akzidenz Super", sans-serif;
    font-size: 28px;
    font-weight: 400;
    letter-spacing: -0.07em;
    line-height: 1;
    color: #000;
    text-decoration: none;
    transition: opacity 0.25s ease;
}

.menu-main:hover {
    opacity: 0.45;
}


/* =====================================
   FLOATING FIELD
===================================== */

.floating-field {
    position: relative;
    width: 100%;
    min-height: 100vh;
    margin: 0 auto;
}

.floating-item {
    position: absolute;
    margin: 0;
    opacity: 0;
    transform: translateY(22px);
    transition:
        opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
        transform 1s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity;
}

.floating-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.floating-motion {
    display: block;
    width: 100%;
    color: inherit;
    text-decoration: none;
    transform: translate3d(0, 0, 0);
    will-change: transform;
}

.floating-image {
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
    transition: opacity 0.35s ease;
}

a.floating-motion:hover .floating-image {
    opacity: 0.72;
}

.floating-empty {
    display: none;
    min-height: 55vh;
}


/* =====================================
   MOBILE
===================================== */

@media (max-width: 700px) {

    .site-page {
        padding: 30px 18px 100px;
    }

    .site-logo-image {
        height: 48px;
        transform: scale(0.8);
        transform-origin: center center;
    }

    .site-role {
        margin-top: 5px;
        font-size: 18px;
    }

    .site-header {
        margin-bottom: 72px;
    }

    .site-edge-nav {
        font-size: 14px;
    }

    .site-edge-left {
        left: 17px;
    }

    .site-edge-right {
        right: 17px;
    }

    .site-instagram {
        bottom: 18px;
        font-size: 11.5px;
    }

    .menu-button {
        top: 20px;
        right: 20px;
        width: 22px;
        height: 13px;
    }

    .menu-button span:nth-child(2) {
        top: 5.5px;
    }

    .menu-button span:nth-child(3) {
        top: 11px;
    }

    .menu-button.active span:nth-child(1),
    .menu-button.active span:nth-child(3) {
        top: 5.5px;
    }

    .menu-main {
        font-size: 26px;
    }
}


/* =====================================
   REDUCED MOTION
===================================== */

@media (prefers-reduced-motion: reduce) {

    .floating-item {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .floating-motion {
        transform: none !important;
    }

    ::view-transition-group(brand-lockup),
    ::view-transition-old(root),
    ::view-transition-new(root) {
        animation-duration: 0.01ms;
    }
}
