@charset "utf-8";

/*=============================
Common
=============================*/

:root {
    --color-navy: #00345d;
    --color-menu: #000242;
    --color-pale: #f4f8fc;
    --color-blue: #537b9e;
}

html {
    font-size: 62.5%;
    scroll-behavior: smooth;
}

body {
    color: var(--color-navy);
    font-family: "Noto Serif JP", "Hiragino Mincho ProN", serif;
    font-size: 1.6rem;
    letter-spacing: 0.08em;
    line-height: 1.5;
    overflow-x: hidden;
}

@media screen and (min-width: 769px) {
    html {
        background: #f6faff;
    }

    body {
        max-width: 1920px;
        margin-right: auto;
        margin-left: auto;
        background: #e9eef2;
    }
}

.line {
    display: block;
    width: 1px;
    height: 40px;
    margin: 0 auto 30px;
    background: #728ba1;
}

h1,
h2,
h3,
p {
    font-weight: 500;
}

@media screen and (min-width: 769px) {
    .line {
        height: 53px;
        margin-bottom: 35px;
    }
}

/*=============================
Buttons
=============================*/

.pill {
    position: absolute;
    font-size: 14px;
    width: 246px;
    padding: 17px 20px;
    bottom: 0;
    left: 50%;
    z-index: 2;
    border-radius: 999px;
    transform: translateX(-50%);
    background: var(--color-navy);
    color: #fff;
    text-align: center;
    white-space: nowrap;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.pill:not(:disabled):hover,
.pill:not(:disabled).is-hover {
    background: #fff;
    color: var(--color-navy);
}

@media screen and (min-width: 769px) {
    .pill {
        padding: 13px 20px;
        width: 300px;
        font-size: 18px;
    }
}
/*=============================
Header
=============================*/

.site-header {
    height: 52px;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 4;
    background: #fff;
}

@media screen and (max-width: 768px) {
    body {
        padding-top: 52px;
    }

    .site-header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
    }
}

.desktop-nav {
    display: none;
}

.nav-services {
    position: relative;
}

.desktop-nav .services-submenu,
.footer-nav .services-submenu {
    position: absolute;
    top: 100%;
    left: -20px;
    width: 230px;
    padding: 16px 0 8px;
    background: #fff;
    box-shadow: 0 8px 16px rgba(0, 52, 93, 0.12);
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.desktop-nav .nav-services:hover .services-submenu,
.desktop-nav .nav-services:focus-within .services-submenu,
.footer-nav .nav-services:hover .services-submenu,
.footer-nav .nav-services:focus-within .services-submenu {
    visibility: visible;
    opacity: 1;
}

.desktop-nav .services-submenu a,
.footer-nav .services-submenu a {
    display: block;
    padding: 12px 20px;
}

.desktop-nav .services-submenu a:hover,
.desktop-nav .services-submenu a:focus-visible,
.footer-nav .services-submenu a:hover,
.footer-nav .services-submenu a:focus-visible {
    background: var(--color-pale);
}

.footer-nav .services-submenu {
    top: auto;
    bottom: 100%;
    padding: 8px 0 16px;
    z-index: 4;
}

#services,
#sns-marketing {
    scroll-margin-top: 80px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 5px;
}

.brand-mark {
    width: 28px;
    height: 28px;
}

.brand-name {
    width: 108px;
}

.menu-button {
    width: 38px;
    height: 32px;
    display: grid;
    place-content: center;
    cursor: pointer;
}

.menu-button span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--color-menu);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

.menu-button span + span {
    margin-top: 7px;
}

.menu-button.is-open span:first-child {
    transform: translateY(4.5px) rotate(45deg);
}

.menu-button.is-open span:last-child {
    transform: translateY(-4.5px) rotate(-45deg);
}

.drawer {
    opacity: 0;
    visibility: hidden;
    min-height: 586px;
    height: 100dvh;
    padding: 106px 73px 0 30%;
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 5;
    pointer-events: none;
    background: linear-gradient(to bottom, transparent 52px, rgba(255, 255, 255, 0.78) 52px);
    transition: opacity 0.25s ease, visibility 0s linear 0.25s;
}

.drawer a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 16px;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 5px;
    padding-right: 50px;
}

.drawer .services-submenu {
    margin: 4px 0 16px;
    padding-left: 12px;
    border-left: 1px solid var(--color-navy);
}

.drawer .services-submenu a {
    font-size: 13px;
}

.desktop-nav .services-submenu .services-subitem,
.footer-nav .services-submenu .services-subitem {
    margin-left: 20px;
    padding-left: 16px;
    border-left: 1px solid #c5d2dd;
    font-size: 12px;
}

.drawer .services-submenu .services-subitem {
    margin-left: 12px;
    padding-left: 8px;
    border-left: 1px solid #c5d2dd;
    font-size: 12px;
}

.drawer {
    overflow-y: auto;
    padding-bottom: 30px;
}

.drawer a::after {
    content: '';
    display: block;
    width: 16px;
    height: 16px;
    margin: 0 0 0 10px;
    flex: 0 0 16px;
    background-image: url("../../images/menu-arrow.svg");
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
}

.drawer-close {
    place-content: center;
    cursor: pointer;
    position: absolute;
    top: 9px;
    right: 22px;
    width: 34px;
    height: 34px;
    display: block;
    padding: 0;
    gap: 0;
    border-radius: 50%;
    border: 2px solid var(--color-menu);
    background: #fff;
}

.drawer-close span {
    display: block;
    width: 16px;
    height: 2px;
    position: absolute;
    top: 50%;
    left: 50%;
    background: var(--color-menu);
    transform: translate(-50%, -50%) rotate(45deg);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

.drawer-close span:last-child {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.drawer.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.25s ease;
}

.drawer.is-closing {
    pointer-events: none;
}

.drawer.is-fading {
    opacity: 0;
}

.drawer.is-closing .drawer-close span:first-child {
    transform: translate(-50%, calc(-50% - 4px)) rotate(0);
}

.drawer.is-closing .drawer-close span:last-child {
    transform: translate(-50%, calc(-50% + 4px)) rotate(0);
}

@media screen and (max-width: 375px) {
    .site-header {
        padding-right: 16px;
        padding-left: 16px;
    }

    .drawer {
        padding-right: 16px;
    }
}

.desktop-nav__contact:hover,
.desktop-nav__contact.is-hover {
    background: #fff;
    color: var(--color-navy);
}

.desktop-nav__contact {
    transition: background-color 0.25s ease, color 0.25s ease;
}

@media screen and (min-width: 769px) {
    .site-header {
        height: 67px;
        padding: 10px 30px;
        position: sticky;
        top: 0;
    }

    .brand-mark {
        width: 42px;
        height: 42px;
    }

    .brand-name {
        width: 186px;
    }

    .desktop-nav {
        display: flex;
        align-items: center;
        gap: 32px;
        font-size: 1.3rem;
        font-weight: 600;
    }

    .desktop-nav__contact {
        padding: 13px 24px;
        border-radius: 999px;
        background: var(--color-navy);
        color: #fff;
    }

    .menu-button {
        display: none;
    }

    .drawer {
        width: 390px;
        right: auto;
        left: 50%;
        transform: translateX(-50%);
    }
}

/*=============================
Contact
=============================*/

.contact-panel a:hover,
.contact-panel a.is-hover {
    background: var(--color-navy);
    color: #fff;
}

.contact {
    position: relative;
    min-height: 512px;
    padding: 35px 32px;
    background-image: linear-gradient(rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.25)), url("../../images/contact-background.jpg");
    background-position: center;
    background-size: cover;
}

.contact-panel {
    padding: 38px 22px 29px;
    background: rgba(51, 103, 143, 0.85);
    color: #fff;
    font-size: 1.4rem;
    line-height: 1.65;
}

.contact-panel h2 {
    margin: 0 0 23px;
    text-align: center;
    font-size: 1.9rem;
}

.contact-panel p {
    margin: 0 0 15px;
}

.contact-panel .tel {
    font-size: 2rem;
}

.contact-panel small {
    display: block;
    margin: -10px 0 22px;
}

.contact-panel a {
    display: block;
    width: 145px;
    margin: 27px auto 0;
    padding: 13px 0;
    border-radius: 999px;
    background: #fff;
    color: var(--color-navy);
    text-align: center;
    font-weight: 600;
    transition: background-color 0.25s ease, color 0.25s ease;
}

@media screen and (min-width: 769px) {
    .contact {
        min-height: 350px;
        padding: 31px;
    }

    .contact-panel {
        max-width: 1280px;
        margin: 0 auto;
        padding: 32px 34px;
    }

    .contact-panel h2 {
        text-align: left;
    }

    .contact-panel a {
        margin-left: 0;
    }
}

/*=============================
Footer
=============================*/

.footer-brand {
    display: flex;
    width: fit-content;
    align-items: center;
    gap: 8px;
}

footer {
    padding: 30px 40px 16px;
    background: #fff;
    font-size: 1.3rem;
    line-height: 1.7;
}

.footer-brand img:first-child {
    width: 42px;
}

.footer-brand img:last-child {
    width: 174px;
}

.footer-brand + p {
    margin: 30px 0 6px;
    font-size: 1.7rem;
}

address {
    font-style: normal;
}

footer small {
    display: block;
    margin-top: 15px;
    font-size: 1.1rem;
}

.footer-nav {
    display: none;
}

@media screen and (min-width: 769px) {
    footer {
        padding: 24px 30px;
        font-size: 1rem;
    }

    .footer-brand + p {
        margin: 10px 0 3px;
        font-size: 1.5rem;
    }

    .footer-brand img:first-child {
        width: 35px;
    }

    .footer-brand img:last-child {
        width: 145px;
    }

    .top-footer {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        column-gap: 32px;
    }

    .top-footer > .footer-brand,
    .top-footer > p,
    .top-footer > address,
    .top-footer > small {
        grid-column: 1;
    }

    .top-footer .footer-nav {
        display: flex;
        grid-column: 2;
        grid-row: 1 / 4;
        align-self: center;
        margin-right: 40px;
        gap: 24px;
        font-size: 13px;
    }

    .footer-nav a:hover,
    .footer-nav a:focus-visible {
        text-decoration: underline;
        text-underline-offset: 5px;
    }
}

/*=============================
Back to top
=============================*/

.back-to-top {
    width: 44px;
    height: 44px;
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 10;
    border: 2px solid var(--color-blue);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    cursor: pointer;
}

.back-to-top::before {
    content: '';
    width: 12px;
    height: 12px;
    position: absolute;
    top: 17px;
    left: 13px;
    border-top: 2px solid var(--color-blue);
    border-left: 2px solid var(--color-blue);
    transform: rotate(45deg);
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

@media screen and (max-width: 768px) {
    .back-to-top {
        right: 16px;
        bottom: 16px;
        width: 40px;
        height: 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .back-to-top {
        transform: none;
        transition: none;
    }
}
