/*
Theme Name: Easychic
Author: 369work
Author URI: https://profiles.wordpress.org/369work/
Description: Easychic is A chic and easy-to-use WordPress theme.
Theme URI: https://easychic.369work.net/
Version: 1.7
Requires at least: 6.6
Tested up to: 6.8
Requires PHP: 8.2
License: GNU General Public License v3 or later
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: blog, portfolio, one-column, right-sidebar, custom-logo, custom-menu, editor-style, featured-images, full-width-template, theme-options
Text Domain: easychic
Domain Path: /languages

This theme, like WordPress, is licensed under the GPL.
*/

/*------------------------------------*\
Include Fonts
/*------------------------------------*/
@font-face {
    font-family: 'Noto Sans JP';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('./assets/fonts/Noto_Sans_JP/NotoSansJP-subset-Regular.woff2') format('woff2');
}

@font-face {
    font-family: 'Noto Serif JP';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('./assets/fonts/Noto_Serif_JP/NotoSerifJP-subset-Regular.woff2') format('woff2');
}

/*------------------------------------*\
Base root CSS
/*------------------------------------*/
:root {
    --color-primary: #1e293b;
    --color-secondary: #bef264;
    --color-tertiary: #7dd3fc;
    --color-primary-hover: #324462;
    --color-text: #687e9d;
    --color-background: #f5f9ff;
    --color-accent: #84cc16;
    --color-link: #475569;
    --color-link-hover: #9fceff;
    --color-link-focus: #7ec9ff;
    --color-link-disabled: #e2e8f0;
    --color-border: #cbd5e1;
    --color-link-dark: #e2e8f0;
}


/*------------------------------------*\
Reset CSS
/*------------------------------------*/

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:where([hidden]:not([hidden='until-found'])) {
    display: none !important;
}

:where(html) {
    -webkit-text-size-adjust: none;
    -moz-text-size-adjust: none;
    text-size-adjust: none;
    color-scheme: dark light;
    tab-size: 2;
    scrollbar-gutter: stable;
    interpolate-size: allow-keywords;
    line-height: 1.5;
}

:where(html:has(dialog:modal[open])) {
    overflow: clip;
}

@media (prefers-reduced-motion: no-preference) {
    :where(html:focus-within) {
        scroll-behavior: smooth;
    }
}

:where(body) {
    line-height: inherit;
    font-family: system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

:where(button) {
    all: unset;
}

:where(input, button, textarea, select) {
    font: inherit;
    color: inherit;
    letter-spacing: inherit;
    word-spacing: inherit;
    font-feature-settings: inherit;
    font-variation-settings: inherit;
}

:where(textarea) {
    resize: vertical;
    resize: block;
}

:where(button, label, select, summary, [role='button'], [role='option']) {
    cursor: pointer;
}

:where(:disabled, label:has(> :disabled, + disabled)) {
    cursor: not-allowed;
}

:where(a) {
    color: inherit;
    text-underline-offset: 0.2ex;
}

:where(ul, ol) {
    list-style: none;
}

:where(img, svg, video, canvas, audio, iframe, embed, object) {
    display: block;
}

:where(img, picture, svg, video) {
    max-inline-size: 100%;
    block-size: auto;
}

:where(p, h1, h2, h3, h4, h5, h6) {
    overflow-wrap: break-word;
}

:where(h1, h2, h3) {
    line-height: calc(1em + 0.5rem);
    text-wrap: balance;
}

:where(hr) {
    border: none;
    border-block-start: 1px solid;
    color: inherit;
    block-size: 0;
    overflow: visible;
}

:where(dialog, [popover]) {
    border: none;
    background: none;
    color: inherit;
    inset: unset;
    max-width: unset;
    max-height: unset;
    overflow: unset;
}

:where(dialog:not([open], [popover]), [popover]:not(:popover-open)) {
    display: none !important;
}

:where(:focus-visible) {
    outline: 3px solid CanvasText;
    box-shadow: 0 0 0 5px Canvas;
    outline-offset: 1px;
}

:where(:focus-visible, :target) {
    scroll-margin-block: 8vh;
}

:where(.visually-hidden:not(:focus-within, :active)) {
    clip-path: inset(50%) !important;
    height: 1px !important;
    width: 1px !important;
    overflow: hidden !important;
    position: absolute !important;
    white-space: nowrap !important;
    border: 0 !important;
    -webkit-user-select: none !important;
    user-select: none !important;
}

/*------------------------------------*\
Font Style
/*------------------------------------*/
.noto-sans-jp {
    font-family: 'Noto Sans JP', sans-serif;
}

.noto-serif-jp {
    font-family: 'Noto Serif JP', serif;
}


/*------------------------------------*\
Global CSS
/*------------------------------------*/
html {
    font-size: 100%;
    -ms-overflow-style: -ms-autohiding-scrollbar;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -webkit-font-feature-settings: "palt"1;
    font-feature-settings: "palt"1;
}

body {
    font-family: sans-serif;
    font-size: clamp(1rem, calc(0.75rem + 1vw), 1.25rem);
    line-height: 1.5;
    color: var(--color-primary);
    scroll-behavior: smooth;
    text-rendering: optimizeLegibility;
    word-break: break-word;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    background-color: var(--color-background);
}

a {
    color: var(--color-link);
    transition: all 0.3s;
}

a:hover {
    color: var(--color-link-hover);
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

button:focus-visible, a:focus-visible {
    outline: 2px solid var(--color-link-focus);
    box-shadow: 0 0 0 3px rgba(99, 214, 255, 0.5);
}

.hidden {
    display: none;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

#page {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 100vh;
}

header {
    background-color: #fff;
    box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    z-index: 1000;
    position: sticky;
    top: 0;
    left: 0;
}

#content {
    flex: 1;
    width: 100%;
}

main {
    width: 100%;
    padding: 2rem 0;
    background-color: #fff;
    min-height: calc(100vh - 300px);
}

aside {
    width: 100%;
    padding: 2rem 0;
    background-color: #f1f5f9;
}

footer {
    width: 100%;
    padding: 2rem 0;
    background-color: #334155;
}

.one-column,
.one-column-none {
    display: flex;
    flex-direction: column;
}

.two-columns {
    display: flex;
    flex-direction: column;
}

.two-columns aside {
    width: 100%;
}

.two-columns main {
    width: 100%;
}

@media screen and (min-width: 1024px) {

    .two-columns {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
    }

    .two-columns aside {
        width: 300px;
    }

    .two-columns main {
        flex: 1;
    }
}



section {
    width: 100%;
    padding: 2rem .5rem;
    border-bottom: 1px solid var(--color-border);
}

section:last-child {
    border-bottom: none;
}


@media screen and (min-width: 1024px) {
    section {
        padding: 2rem;
    }
}

.menu_open_button {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 60px;
    height: 32px;
    border: none;
    color: var(--color-text);
    cursor: pointer;
    transition: all 0.3s;
    z-index: 10;
    text-decoration: none;
}

.menu_open_button:hover {
    color: var(--color-link-hover);
    opacity: .8;
}

.menu_open_button .bar {
    width: 100%;
    height: 4px;
    background-color: var(--color-text);
    transition: all 0.3s;
}

.menu_open_button.open .bar:nth-child(1) {
    transform: rotate(45deg) translate(10px, 10px);
}

.menu_open_button.open .bar:nth-child(2) {
    opacity: 0;
}

.menu_open_button.open .bar:nth-child(3) {
    transform: rotate(-45deg) translate(10px, -10px);
}

@media screen and (min-width: 1024px) {
    .menu_open_button {
        display: none;
    }
}

.sp_menu_modal {
    position: fixed;
    top: 58px;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 9;
    animation: slideIn 0.5s forwards;
    padding: 2rem;
    overflow-y: auto;
    overscroll-behavior-y: contain;
}

@media screen and (min-width: 768px) {
    .sp_menu_modal {
        top: 70px;
    }
}

.sp_menu_modal[aria-hidden="true"] {
    display: none;
}

.sp_menu_modal[aria-hidden="false"] {
    display: flex;
    justify-content: center;
}

.modal_content {
    width: 100%;
    height: fit-content;
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid var(--color-border);
    border-radius: .5rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

ul.sp_menu {
    list-style: none;
}

ul.sp_menu>li {
    border-bottom: 1px solid var(--color-border);
}

ul.sp_menu li a {
    display: block;
    padding: 1rem 0;
    color: var(--color-link-hover);
}

ul.sp_menu a:hover {
    color: var(--color-tertiary);
}

ul.sp_menu ul.children li {
    padding-left: 1rem;
}

ul.sp_menu ul.children li:first-child {
    border-top: 1px solid var(--color-secondary);
}

ul.sp_menu ul.children li {
    border-bottom: 1px solid var(--color-secondary);
}

ul.sp_menu ul.children li:last-child {
    border-bottom: none;
}

.menu_close_button {
    display: flex;
    margin: 1rem 0;
    padding: .5rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: .5rem;
    color: var(--color-background);
    cursor: pointer;
    transition: all 0.3s;
}

.menu_close_button:hover {
    background-color: var(--color-link-hover);
    color: var(--color-text);
}

.pc_menu {
    display: none;
}

@media (min-width: 1024px) {

    .pc_menu {
        display: flex;
        flex-wrap: wrap;
        gap: 1.5rem;
        font-size: 1rem;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .pc_menu li a {
        display: block;
        padding: 0.5rem 0;
        color: #333;
        text-decoration: none;
        position: relative;
        transition: color 0.3s ease;
    }

    .pc_menu li a::after {
        content: '';
        position: absolute;
        width: 0;
        height: 2px;
        bottom: 0;
        left: 0;
        background-color: var(--color-link-focus);
        transition: width 0.3s ease;
    }

    .pc_menu li a:hover {
        color: var(--color-link-focus);
    }

    .pc_menu li a:hover::after {
        width: 100%;
    }

    .pc_menu li a:focus {
        outline: 2px solid var(--color-link-focus);
        outline-offset: 2px;
        color: var(--color-link-focus);
    }

    .pc_menu li a:focus::after {
        width: 100%;
    }

    .pc_menu .sub-menu li a {
        padding: .5rem;
    }

    .pc_menu .sub-menu {
        position: absolute;
        top: 100%;
        left: 0;
        background-color: var(--color-background);
        min-width: 200px;
        padding: .5rem 0;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        z-index: 1000;
        list-style: none;
    }

    .menu-item-has-children {
        position: relative;
    }

    .menu-item-has-children:hover .sub-menu,
    .menu-item-has-children:focus-within .sub-menu {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

}

.skip-link {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.skip-link:focus {
    background-color: #f8fafc;
    clip: auto !important;
    clip-path: none;
    color: #5898ff;
    display: block;
    font-weight: bold;
    height: auto;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    width: auto;
    z-index: 100000;
    position: relative;
}

@keyframes slideIn {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(0);
    }
}

.page-top {
    position: fixed;
    bottom: 200px;
    right: 30px;
    z-index: 100;
    display: block;
}

.page-top a {
    width: 60px;
    height: 60px;
    display: block;
    text-align: center;
    color: var(--color-link);
    text-transform: uppercase;
    text-decoration: none;
    font-size: 0.6rem;
    background: url("assets/images/arrow-1.webp") no-repeat center;
    background-size: contain;
}

.page-top a:hover {
    color: var(--color-link-hover);
    background: url("assets/images/arrow-2.webp") no-repeat center;
    background-size: contain;
}

.page-top span {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--color-link);
}

@media (min-width: 1024px) {
    .page-top {
        right: 50px;
        bottom: 100px;
    }
}

.container {
    width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .container {
        max-width: 768px;
    }
}

@media (min-width: 1024px) {
    .container {
        max-width: 1024px;
    }
}

@media (min-width: 1280px) {
    .container {
        max-width: 1280px;
    }
}

@media (min-width: 1536px) {
    .container {
        max-width: 1536px;
    }
}

.archive-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-top: 2rem;
}

@media (min-width: 768px) {
    .archive-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }

}

.archive-post {
    display: flex;
    flex-direction: column;
    margin-bottom: 4rem;
    border: 1px solid var(--color-border);
    border-radius: .5rem;
    overflow: hidden;
    padding: 1rem;
    background-color: #fff;
}

.front-grid {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    height: 100%;
}

.front-post {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--color-border);
    border-radius: .5rem;
    overflow: hidden;
    padding: .5rem;
    background-color: #fff;
}

.front-header {
    flex: 1;
    min-height: 50px;
}

.front-title {
    font-size: clamp(1.15rem, calc(0.75rem + 1vw), 1.25rem);
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.front-thumbnail {
    width: 100%;
    height: 48%;
    overflow: hidden;
    margin-bottom: .5rem;
}

.front-thumbnail:nth-child(1) {
    height: 72%;
}

.front-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (min-width: 768px) {
    .front-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 320px;
        padding: 1rem;
    }

    .front-post:nth-child(1) {
        grid-column: 1 / 3;
        grid-row: 1 / 3;
    }
}

@media (min-width: 1280px) {
    .front-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-auto-rows: 300px;
        padding: 1rem;
    }

    .front-post:nth-child(1) {
        grid-column: 1 / 3;
        grid-row: 1 / 3;
    }
}


.index-post {
    display: flex;
    flex-direction: column;
    margin-bottom: 4rem;
}

.nav-post {
    margin-top: 3rem;
    border-top: 1px solid var(--color-border);
    padding-top: 2rem;
}