@charset "UTF-8";
/*
Theme Name: Bookstyle V4
Theme URI: bookstyle.xyz
Description: Bookstyle WordPress Theme Renewed (v4)
Version: 1.0.0
Author: ねり (Renewal by Antigravity)
Author URI: bookstyle.xyz
*/

/* CSS Variables for v4 design */
:root {
    --primary-color: #333;
    --sidebar-width: 250px;
    --sidebar-bg: #EAEAEA;
    --bg-color: #fcfcfc;
    --wood-color: #DEB887;
    --wood-dark: #8B4513;
    --text-color: #333;
    --link-color: #000;
}

/* Reset & Basics */
html,
body {
    margin: 0;
    padding: 0;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    /* Unify background on body */
    background: #fcfcfc url('images/bg_common.jpg') no-repeat 0 0 fixed;
    background-size: cover;
    color: var(--text-color);
    height: 100%;
}

* {
    box-sizing: border-box;
}

ul,
ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

a {
    text-decoration: none;
    color: var(--link-color);
    transition: opacity 0.3s;
}

/* a:hover {
    opacity: 0.7;
} */

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

.lightbox {
    cursor: pointer;
    display: block;
}

/* アクセントフォント */
.oswald {
  font-family: "Oswald", sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
}

/* Layout */
#wrapper {
    display: flex;
    flex-wrap: wrap;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    /* Remove separate background */
    background: transparent;
    padding: 20px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    /* Scroll if sidebar content is too long */
    /* height: auto;  Let it grow with content or stretch */
    z-index: 100;
}

.sidebar-logo {
    margin-top: 0;
    margin-left: 20px;
    margin-bottom: 40px;
}
/* ... skipped ... */
/* Main Content */
.l_main {
    /* margin-left: var(--sidebar-width); Removed for flex layout */
    width: calc(100% - var(--sidebar-width));
    /* margin-left: var(--sidebar-width); Removed for sticky layout */
    /* Add space for fixed sidebar */
    padding-bottom: 40px;
    /* Space for footer */
    /* Transparent to show body background */
    background: transparent;
}

.sidebar-logo h1 {
    font-size: 0;
    /* Hide text, use image or styled box */
}

.logo-box {
    display: block;
    width: 90%;
    padding-bottom: 30px;
    border: 8px solid #333;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 10px 15px -3px, rgba(0, 0, 0, 0.05) 0px 4px 6px -2px;
    background: #2e558f;
    font-size: 55px;
    color: #fff;
    line-height: 1em;
    text-align: center;
    font-family: "Oswald", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
}

.logo-box span{
    font-size: 14px;
    line-height: 1em;
    font-weight: normal;
    display: inline-block;
    margin-bottom: 1em;
}

.logo-img {
    display: block;
    width: 100%;
    height: auto;
}

/* Navigation */
.gMenu-list {
    display: flex;
    flex-wrap: wrap;
}

.gMenu-list li {
    margin-bottom: 10px;
    margin-left: 15px;
    width: 40%;
}

.gMenu-list li a {
    font-size: 20px;
    /* letter-spacing: 1px; */
    color: #333;
    font-family: "Oswald", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
    font-style: normal;
    position: relative;
    transition: opacity 0.3s, color 0.3s;
}

.gMenu-list li a::before {
    content: ">";
    position: absolute;
    left: -15px;
    color: #2e558f;
    opacity: 0;
    transition: opacity 0.3s;
}

.gMenu-list li a:hover::before,
.gMenu-list li.current-menu-item a::before,
.gMenu-list li.current-menu-ancestor a::before,
.gMenu-list li.current_page_item a::before,
.gMenu-list li.active a::before {
    opacity: 1;
}

.gMenu-list li a:hover,
.gMenu-list li.current-menu-item a,
.gMenu-list li.current-menu-ancestor a,
.gMenu-list li.current_page_item a,
.gMenu-list li.active a {
    color: #2e558f;
}


/* Sidebar News */
.sidebar-news {
    margin-top: 20px;
    margin-bottom: 30px;
}

.news-item {
    font-size: 13px;
    line-height: 1.5;
}

.news-date {
    color: #888;
    margin-bottom: 3px;
    font-size: 11px;
}

.news-title {
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.news-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.news-title a:hover {
    color: #2e558f;
    text-decoration: underline;
}

/* Search Box */
.sidebar-search {
    margin-top: 20px;
}

.search-label {
    font-weight: bold;
    margin-bottom: 10px;
    display: block;
    border-bottom: 1px solid #ccc;
    padding-bottom: 5px;
}

.search-form input[type="text"] {
    width: 100%;
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Social Icons */
.sidebar-social {
    margin-top: 20px;
    display: flex;
    gap: 10px;
}

.sidebar-social img {
    width: 40px;
}

/* Main Content */
.l_main {
    /* margin-left: var(--sidebar-width); Removed for flex layout */
    width: calc(100% - var(--sidebar-width));
    /* Add space for fixed sidebar */
    padding-bottom: 40px;
    /* Space for footer */
    /* Transparent to show body background */
    background: transparent;
}

@media screen and (max-width: 768px) {
    /* Main layout adjustment for mobile if needed, though previously it only had bg adjustments */
}

.l_wrap {
    max-width: 1380px;
    margin: 0 auto 0 5%;
    padding: 0 40px;
}

/* Shelf Design (Front Page) */
.book-shelf-row {
    padding: 20px 0 0 0;
    margin-top: 50px;
    margin-bottom: 0;
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap; /* Restore wrapping */
    gap: 0; /* No gap between items to keep background seamless */
    position: relative;
    z-index: 3;
    width: 100%;
}

.cover-item {
    width: 180px; /* Fixed width to match shelf background repeat if possible */
    text-align: center;
    position: relative;
    margin-bottom: 40px; /* Space for the next shelf line */
    z-index: 5;
    padding-bottom: 23px; /* Push item up from shelf edge */
}

.cover-item::before {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 243px;
    background: url('images/bg_display.png');
    background-repeat: no-repeat;
    background-position: bottom center;
    /* background-size: 100% auto; */
    z-index: -1;
}

.cover-item:hover .cover-image {
    transform: translateY(-8px) scale(1.05);
}

.cover-image {
    transition: transform 0.2s;
}

.cover-item:hover {
    /* transform: translateY(-5px); Removed to keep shelf static */
    opacity: 1;
}

.cover-image img {
    /* box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2); */
    box-shadow: 4px 0px 9px 1px rgba(0, 0, 0, 0.23);
    display: block;
    margin: 0 auto;
    width: 145px;
    height: 200px;
    max-width: 145px; /* Force size to prevent overflow */
    object-fit: cover;
    object-position: 100% 100%;
    border-radius: 5px 0px 0px 3px;
}

/* Footer */
.footer {
    padding: 20px;
    background: url('images/bg_footer.jpg');
    /* Footer background */
    background-size: cover;
    /* Dark brown */
    color: #fff;
    text-align: center;
    position: relative;
    z-index: 500;
    /* Full width to overlay sidebar */
    width: 100%;
    margin-left: 0;
}

.footer .cat-image {
    position: fixed; /* Changed to fixed default */
    right: 0px;
    bottom: -20px;
    top: auto;
    width: 130px;
    z-index: 501;
    /* Initial state: Hidden (pushed off-screen) */
    transform: translateX(200%); /* Start hidden */
    transition: transform 0.5s ease-out;
    cursor: pointer; /* Clickable */
}

/* Floating State (Fixed) */
.footer .cat-image.is-floating {
    position: fixed;
    right: 0px;
    bottom: -20px;
    top: auto;
    transform: translateX(0); /* Align to screen */
}

/* Docked State (Absolute on Footer) */
.footer .cat-image.is-docked {
    position: absolute;
    right: 0px;
    top: -70px; /* Original dock position */
    bottom: auto;
    transform: translateX(0);
}

/* Leaving State (Click to hide) */
.footer .cat-image.is-leaving {
    transform: translateX(200%);
    position: fixed; /* Ensure fixed while leaving */
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.modal-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
}

.modal-content {
    background: #fff;
    width: 800px;
    /* Match design wide aspect */
    max-width: 90%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.modal-close {
    position: absolute;
    right: 0px;
    top: -60px;
    font-size: 60px;
    cursor: pointer;
    color: #fff;
}

/* Modal Checkbox Size */
.terms-check label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.terms-check label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    margin: 0;
}

/* Gallery Modal specific styles */
.modal.is-gallery-modal .modal-header,
.modal.is-gallery-modal .terms-check,
.modal.is-gallery-modal .action-buttons,
.modal.is-gallery-modal .modal-tags {
    display: none !important;
}

/* Modal Swiper Styles */
.modal-image-container.swiper {
    width: 100%;
    margin-bottom: 20px;
    padding-bottom: 40px; /* Space for pagination and gap */
}

.modal-image-container.swiper .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-image-container.swiper .swiper-slide img {
    max-width: 100%;
    max-height: 70vh; /* Prevent it from getting too tall */
    object-fit: contain;
}

/* Customize Swiper Pagination */
.modal-image-container .swiper-pagination {
    bottom: 0 !important; /* Move dots to the bottom edge of the container */
}

.modal-image-container .swiper-pagination-bullet-active {
    background: #35538e; /* Theme blue */
}

/* Make dots larger and spaced out */
.modal-image-container .swiper-pagination-bullet {
    width: 15px;
    height: 15px;
    margin: 0 8px !important;
}

.modal.is-gallery-modal .modal-content {
    background: transparent; /* Optional: make background transparent if just showing image */
    box-shadow: none;
    border: none;
    max-width: 90%; /* Allow larger width for image */
    width: auto;
}

.modal.is-gallery-modal .modal-body {
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal.is-gallery-modal .modal-image-container {
    background: transparent;
    padding: 0;
}

.modal.is-gallery-modal .modal-close {
    color: #fff; /* White close button for dark/transparent background */
    top: -30px;
    right: -30px;
    opacity: 0.8;
}


.modal-header {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.modal-image-container {
    text-align: center;
    margin-bottom: 20px;
}

.modal-image-container img {
    max-height: 490px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.modal-actions {
    text-align: center;
}

.bd-link{
    color:#35538e;
    text-decoration: underline;
    font-weight: bold;
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}


.arrow::before {
    content: "";
    position: absolute;
    top: calc(50% - 1.5px);
    right: 0;
    width: 12px; /* Adjusted length to look balanced */
    height: 3px;
    border-radius: 9999px;
    background-color: #ffffff;
    transform: rotate(45deg);
    transform-origin: calc(100% - 1.5px) 50%;
}

.arrow::after {
    content: "";
    position: absolute;
    top: calc(50% - 1.5px);
    right: 0;
    width: 12px; /* Adjusted length to look balanced */
    height: 3px;
    border-radius: 9999px;
    background-color: #ffffff;
    transform: rotate(-45deg);
    transform-origin: calc(100% - 1.5px) 50%;
}

.btn {
    padding: 10px 30px;
    border-radius: 5px;
    /* color: #fff;  Removed global white color */
    font-weight: bold;
    display: inline-flex; /* Use flex for vertical alignment */
    align-items: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: color 0.2s cubic-bezier(0.45, 0, 0.55, 1);
}

/* General Slide Effect */
.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: scale(0, 1);
    transform-origin: left top;
    transition: transform 0.2s cubic-bezier(0.45, 0, 0.55, 1);
    z-index: -1;
}

.btn:hover {
    color: #fff;
    text-decoration: none;
}

.btn:hover::after {
    transform: scale(1, 1);
}

/* Button Specifics */
.btn-green {
    background: #fff;
    color: #32CD32;
    border: 2px solid #32CD32;
}

.btn-green::after {
    background: #32CD32;
}

.btn-blue {
    background: #fff;
    color: #00BFFF;
    border: 2px solid #00BFFF;
}

.btn-blue::after {
    background: #00BFFF;
}

/* Disabled State */
.btn.bd-disabled {
    background: #fff !important;
    color: #aeaeae !important;
    border-color: #aeaeae !important;
    pointer-events: none;
    cursor: default;
}

.btn.bd-disabled::after {
    display: none;
}

.btn.bd-disabled .arrow,
.btn.bd-disabled .arrow::before,
.btn.bd-disabled .arrow::after {
    background-color: #aeaeae !important;
}

/* Arrow Colors syncing with text */
.btn-green .arrow,
.btn-green .arrow::before,
.btn-green .arrow::after {
    background-color: #32CD32;
    transition: background-color 0.2s cubic-bezier(0.45, 0, 0.55, 1);
}

.btn-blue .arrow,
.btn-blue .arrow::before,
.btn-blue .arrow::after {
    background-color: #00BFFF;
    transition: background-color 0.2s cubic-bezier(0.45, 0, 0.55, 1);
}

.btn-green:hover .arrow,
.btn-green:hover .arrow::before,
.btn-green:hover .arrow::after,
.btn-blue:hover .arrow,
.btn-blue:hover .arrow::before,
.btn-blue:hover .arrow::after {
    background-color: #fff;
}

.btn:hover .arrow {
    transform: translateX(3px);
}

.arrow {
    position: relative;
    display: inline-block;
    width: 20px;
    transition: transform 1s ease-out; /* Smoother easing */
    will-change: transform;
}

/* Blog Post Navigation Arrows */
.post-navigation .arrow::before,
.post-navigation .arrow::after {
    background-color: #6AACB8;
}

/* ==========================================================================
   Works & Gallery Styles (Ported from bookstyle2025)
   ========================================================================== */

/* Title Styles */


h3.h3 {
    background-image: url("images/icon-s22da8f8f13.png");
    /* Need to ensure image exists or path is correct */
    background-repeat: no-repeat;
    background-position: 0 -133px;
    height: 27px;
    color: #0E0A32;
    margin: 20px 0 10px 0;
    padding-left: 30px;
    font-size: 18px;
    line-height: 27px;
}

/* Works List */
ul.workList {
    margin-bottom: 20px;
}

ul.workList li {
    padding: 15px 0;
    border-bottom: 1px dashed #A5A5A5;
    list-style: none;
}

ul.workList li:first-child {
    padding-top: 0;
}

.workList__tit {
    font-weight: bold;
    font-size: 16px;
    margin-bottom: 5px;
}

.workList__cont {
    color: #595959;
    font-size: 14px;
    line-height: 1.6;
}

.newIcon--second {
    background-color: #ffcd4a;
    border-radius: 3px;
    float: left;
    font-size: 0.8em;
    margin-right: 5px;
    padding: 0 6px;
    text-align: center;
    color: #333;
}

/* Gallery Grid */
ul.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
}

ul.gallery>li {
    width: calc(33.333% - 14px);
    /* 3 column layout approx */
    margin: 0;
    padding: 0;
    list-style: none;
    background: #fff;
    padding: 15px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

ul.gallery>li p {
    margin: 0 0 10px 0;
}

ul.gallery .gallery__date {
    font-size: 0.8em;
    color: #999;
    text-align: right;
}

ul.gallery .gallery__photo {
    margin-bottom: 10px;
    text-align: center;
}

ul.gallery .gallery__photo img {
    max-width: 100%;
    height: auto;
    border: 1px solid #eee;
}

ul.gallery__tagbox {
    margin-bottom: 10px;
    overflow: hidden;
}

ul.gallery__tagbox li {
    float: left;
    list-style: none;
    margin-right: 5px;
    margin-bottom: 5px;
    background-color: #6AACB8;
    border: 1px solid #6AACB8;
    border-radius: 3px;
    color: #fff;
    font-size: 11px;
    padding: 2px 6px;
}

.gallery__client {
    font-size: 0.9em;
    font-weight: bold;
    margin-bottom: 5px;
}

.gallery__content {
    font-size: 0.9em;
    color: #333;
}

/* Adjustments for responsive */
@media screen and (max-width: 768px) {
    ul.gallery>li {
        width: calc(50% - 10px);
    }
}

@media screen and (max-width: 480px) {
    ul.gallery>li {
        width: calc(50% - 10px); /* Keep 2 columns on mobile */
    }
}

/* Page Content Container - Refined for paper/sheet look */
.content-container {
    background: rgb(255 255 255 / 0.65);
    padding: 60px;
    /* border-radius: 0;  Sharp edges like paper */
    margin: 20px auto;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
    /* Soft shadow */
    max-width: 1000px;
    /* Constrain width for readability */
}

/* Sidebar Color Dots */
.color-dot {
    display: block;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    border: 1px solid #ddd;
    box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.color-brown {
    background-color: #4e2f0b;
}

.color-blue {
    background-color: #00BFFF;
}

.color-yellow {
    background-color: #ffee00;
}

.color-green {
    background-color: #32CD32;
}

.color-white {
    background-color: #fff;
}

.color-red {
    background-color: #FF4500;
}

.color-colorful {
    background: conic-gradient(#FF4500 0% 25%,
            #00BFFF 25% 50%,
            #FFD700 50% 75%,
            #32CD32 75% 100%);
}

/* ==========================================================================
   Unified Page Styles (About, Works, Gallery, HowTo)
   ========================================================================== */

/* Header Area */
.unified-header {
    margin-top: 70px;
    margin-bottom: 40px;
    text-align: center;
}

.unified-title-en {
    font-size: 70px;
    margin: 0;
    line-height: 1;
    color: #333;
    font-family: "Oswald", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
    font-style: normal;
}

.unified-title-jp {
    font-size: 17px;
    color: #666;
    letter-spacing: 2px;
    margin-top: 5px;
}

/* Intro Section (Flex Layout) */
.unified-intro {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
    margin-bottom: 60px;
}

.unified-intro-text {
    flex: 1;
}

.unified-intro-image {
    width: 400px;
    /* Adjust based on image aspect ratio */
    flex-shrink: 0;
}

.unified-intro-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.unified-lead {
    font-weight: bold;
    margin-bottom: 20px;
    font-size: 1.1em;
}

/* Pink Marker Highlighter */
.marker {
    background: linear-gradient(transparent 50%, #f2eda4 70%);
    /* Light pink marker */
    font-weight: bold;
}

/* Section Titles with Pink Icon (H3) */
.icon-heading,
.unified-section h3 {
    font-size: 22px;
    font-weight: bold;
    margin-top: 40px;
    margin-bottom: 15px;
    position: relative;
    padding-left: 30px;
    color: #333;
    background: none;
    /* Override previous h3 styles if needed */
}

.icon-heading::before,
.unified-section h3::before {
    content: '';
    position: absolute;
    left: 0;
    top: 2px; /* Adjusted for image alignment */
    width: 26px; /* Increased for image visibility */
    height: 26px;
    background: url("images/icon_h3.png") no-repeat center center;
    background-size: contain;
}

/* Styled H2 (Center with marker underline) */
h2.unified-h2,
.unified-section h2 {
    text-align: center;
    border: none;
    font-size: 45px;
    font-weight: bold;
    padding-bottom: 5px; /* Space for the line image */
    display: inline-block;
    position: relative;
    background: url("images/line_h2.png") no-repeat center bottom;
    width: auto;
    padding-left: 10px;
    padding-right: 10px;
    display: table;
    /* Center centering */
    margin: 30px auto 30px auto;
}

h2.unified-h2::after {
    display: none;
    /* Remove default h2 line */
}

/* Section spacing */
.unified-section {
    margin-bottom: 60px;
}

/* Responsive */
@media screen and (max-width: 768px) {
    .unified-header {
        margin-top: 55px;
    }
    .unified-intro {
        flex-direction: column-reverse;
    }

    .unified-intro-image {
        width: 100%;
        margin-bottom: 20px;
    }

    .unified-intro-text {
        width: 100%;
    }
}

/* ==========================================================================
   Search Functionality V4 Styles
   ========================================================================== */

/* Search Items Wrapper */
.search-item {
    margin-bottom: 10px;
}

/* Select Box Styling */
.search-select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 14px;
    appearance: none;
    /* Custom arrow if needed, or stick to browser default for now */
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23333%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right .7em top 50%;
    background-size: .65em auto;
    border-radius: 20px;
}

/* Color Search Wrapper */
.sidebar-color-search {
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.color-dots {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* Hide Radio Buttons */
.color-dot-wrapper input[type="radio"] {
    display: none !important;
}

/* The Color Dot */
.color-dot {
    display: block;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    border: 1px solid #ddd;
    box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

/* Hover State */
.color-dot:hover {
    transform: scale(1.1);
}

/* Active State (Checked) */
.color-dot-wrapper input[type="radio"]:checked+.color-dot {
    transform: scale(1.2);
    box-shadow: 0 0 0 2px #333;
    /* Ring effect */
    border-color: #333;
}

/* Clear Selection Button (Optional, not requested but good UX) */
.clear-search {
    display: block;
    margin-top: 10px;
    font-size: 12px;
    text-align: right;
    color: #999;
}
/* ==========================================================================
   Blog Styles
   ========================================================================== */

.blog-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin: 40px auto;
    max-width: 1200px; /* Slightly wider for grid */
    padding-bottom: 50px;
}

.blog-item {
    background: rgb(255 255 255 / 0.65);
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.blog-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.blog-item-inner {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    gap: 0;
    width: 100%;
    height: 100%;
}

.blog-item-thumb {
    width: 100%;
    height: 200px;
    flex-shrink: 0;
    overflow: hidden;
}

.blog-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-item-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.blog-item-meta {
    font-size: 13px;
    color: #888;
    margin-bottom: 10px;
}

.blog-item-meta .category {
    margin-left: 10px;
    color: #6AACB8;
}

.blog-item-title {
    font-size: 18px;
    margin: 0 0 10px 0;
    line-height: 1.4;
    color: #333;
    font-weight: bold;
}

.blog-item-excerpt {
    font-size: 13px;
    color: #666;
    line-height: 1.6;
}

/* Blog Detail Specifics */
.post-meta-top {
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: #888;
}

.blog-body {
    line-height: 2;
    color: #333;
}

.blog-body p {
    margin-bottom: 2em;
}

.blog-body h2 {
    text-align: center;
    border: none;
    font-size: 45px;
    font-weight: bold;
    padding-bottom: 5px;
    display: inline-block;
    position: relative;
    background: url('images/line_h2.png') no-repeat center bottom;
    width: auto;
    padding-left: 10px;
    padding-right: 10px;
    display: table;
    margin: 40px auto 40px auto;
}

.blog-body h3 {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 15px;
    position: relative;
    padding-left: 30px;
    color: #333;
    background: none;
}

.blog-body h3::before {
    content: '';
    position: absolute;
    left: 0;
    top: 2px;
    width: 26px;
    height: 26px;
    background: url('images/icon_h3.png') no-repeat center center;
    background-size: contain;
}

/* Pagination */
.pagination {
    margin-top: 50px;
    text-align: center;
}

@media screen and (max-width: 768px) {
    .pagination {
        margin-bottom: 80px;
    }
}

.pagination a, .pagination span {
    display: inline-block;
    padding: 8px 16px;
    margin: 0 5px;
    border: 1px solid #ddd;
    border-radius: 5px;
    text-decoration: none;
    color: #333;
}

.pagination .current {
    background: #6AACB8;
    border-color: #6AACB8;
    color: #fff;
}

/* Responsive Blog */
@media screen and (max-width: 1024px) {
    .blog-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 768px) {
    .blog-list {
        grid-template-columns: 1fr;
        padding: 0 20px;
    }
    .blog-item-thumb {
        height: 180px;
    }
}

/* ==========================================================================
   Content Lists (Subpages)
   ========================================================================== */
.content-container ul:not(.gallery):not(.workList):not(.gallery__tagbox),
.blog-body ul {
    list-style: none;
    padding: 0;
    margin: 0 0 2em 0;
}

.content-container ul:not(.gallery):not(.workList):not(.gallery__tagbox) > li,
.blog-body ul > li {
    position: relative;
    padding-left: 1.5em;
    margin-bottom: 1.3em;
    background: url('images/icon_list.png') no-repeat left 0.4em;
}

/* ==========================================================================
   Form Styles (Mail Page / General Forms)
   ========================================================================== */

/* Form wrappers and layout */
.content-container form {
    margin-top: 20px;
}

.content-container form p {
    margin-bottom: 20px;
}

/* Base Input Styles */
.content-container input[type="text"],
.content-container input[type="email"],
.content-container input[type="tel"],
.content-container input[type="url"],
.content-container textarea,
.content-container select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #fafafa;
    font-size: 16px;
    color: #333;
    transition: border-color 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
    font-family: inherit;
}

/* Textarea specific */
.content-container textarea {
    min-height: 150px;
    resize: vertical;
}

/* Focus State */
.content-container input[type="text"]:focus,
.content-container input[type="email"]:focus,
.content-container input[type="tel"]:focus,
.content-container textarea:focus,
.content-container select:focus {
    outline: none;
    border-color: #35538e;
    background-color: #fff;
    box-shadow: 0 0 5px rgba(53, 83, 142, 0.2);
}

/* Labels */
.content-container label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
    color: #333;
}

/* Submit Button */
.content-container input[type="submit"],
.content-container button[type="submit"] {
    display: inline-block;
    padding: 15px 40px;
    background-color: #35538e;
    color: #fff;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    margin-top: 10px;
    text-align: center;
}

.content-container input[type="submit"]:hover,
.content-container button[type="submit"]:hover {
    background-color: #2e558f;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

/* Table layout forms */
.content-container table.form-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.content-container table.form-table th,
.content-container table.form-table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.content-container table.form-table th {
    width: 30%;
    text-align: left;
    font-weight: bold;
    background-color: #fcfcfc;
}

/* Blog Category List Navigation */
.blog-category-nav {
    margin-bottom: 40px;
    text-align: center;
}

.blog-category-heading {
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
    display: block;
}

.blog-category-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.blog-category-list li {
    list-style: none;
    background: none !important;
    padding-left: 0 !important;
    margin-bottom: 0 !important;
}

.blog-category-list li a {
    display: inline-block;
    background-color: #6AACB8;
    color: #fff;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-category-list li a:hover,
.blog-category-list li a.is-active {
    background-color: #589ca7;
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(106, 172, 184, 0.4);
    color: #fff;
}

/* Single Blog Sidebar Layout */
.blog-single-wrapper {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    margin: 20px auto;
    max-width: 1000px; /* same as .content-container but used as wrapper */
}

.blog-single-wrapper .content-container {
    margin: 0;
    flex: 1;
    min-width: 0;
    padding: 60px; /* retain from original */
}

.blog-sidebar {
    width: 200px;
    flex-shrink: 0;
    margin-top: 0;
    position: sticky;
    top: 40px;
}

.blog-category-vertical .blog-category-list {
    flex-direction: column;
    align-items: stretch;
}

/* Hide SP-only select by default */
.blog-category-select-wrapper {
    display: none;
}

.blog-category-vertical .blog-category-list li a {
    display: block;
    text-align: center;
}

@media screen and (max-width: 768px) {
    .blog-single-wrapper {
        flex-direction: column;
        padding: 0;
    }
    .blog-sidebar {
        width: 100%;
    }
    .blog-single-wrapper .content-container {
        padding: 0;
        width: 100%;
    }
    .blog-category-list {
        display: none;
    }
    .blog-category-select-wrapper {
        display: block;
        margin-bottom: 20px;
    }
    .blog-category-select {
        width: 100%;
        padding: 10px;
        font-size: 16px;
        border: 1px solid #ddd;
        border-radius: 4px;
        background-color: #fff;
    }
}

/* ==========================================================================
   Page Transition Animations
   ========================================================================== */
body {
    /* Hide scrollbar during transition if needed, but fade is usually fine */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s;
}

body.is-loaded {
    opacity: 1;
    visibility: visible;
}

.page-transition {
    animation: fadeSlideUp 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes fadeSlideUp {
    0% {
        opacity: 0;
        transform: translateY(15px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   SP Header & Smartphone Layout
   ========================================================================== */
.sp-header,
.sp-news-section,
.sp-advanced-search,
.sp-menu-overlay {
    display: none;
}

@media screen and (max-width: 768px) {
    /* SP Background Override & iOS Fixed Background Fix */
    html, body {
        /* Remove the background from html and body to prevent PC background showing during fade */
        background-image: none !important;
        background-color: transparent !important;
    }
    
    html::before {
        content: "";
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: #fcfcfc url('images/bg_common_sp.png') no-repeat center center;
        background-size: cover;
        z-index: -100;
        /* prevent clicking the pseudo element */
        pointer-events: none;
    }

    /* Hide Sidebars */
    .sidebar {
        display: none !important;
    }

    /* Adjust main to full width */
    .l_main {
        width: 100%;
    }

    /* SP Header */
    .sp-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: absolute; /* Changed from fixed to absolute */
        top: 0;
        left: 0;
        width: 100%;
        height: 60px;
        background-color: #2e558f;
        z-index: 1005; /* Increase to beat advanced search 1001 */
        padding: 0 15px;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    .sp-header-title {
        color: #fff;
        font-family: "Oswald", sans-serif;
        font-size: 24px;
        margin: 0;
        font-weight: bold;
    }

    .sp-header-title a {
        color: #fff;
        text-decoration: none;
    }

    /* Hamburger Menu Button */
    .hamburger {
        position: fixed;
        top: 8px;
        right: 15px;
        width: 44px;
        height: 44px;
        background-color: rgba(46, 85, 143, 0.9);
        border-radius: 6px;
        cursor: pointer;
        z-index: 1006; /* Above header and search */
        box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    }

    .hamburger span {
        display: block;
        position: absolute;
        height: 2px;
        width: 30px; /* Set specific width for lines */
        background: #fff;
        border-radius: 2px;
        opacity: 1;
        left: 7px; /* Center inside 44px container */
        transition: .25s ease-in-out;
    }

    .hamburger span:nth-child(1) { top: 12px; }
    .hamburger span:nth-child(2) { top: 21px; }
    .hamburger span:nth-child(3) { top: 30px; }

    .hamburger.is-active span:nth-child(1) {
        top: 21px;
        transform: rotate(135deg);
    }

    .hamburger.is-active span:nth-child(2) {
        opacity: 0;
        left: -60px;
    }

    .hamburger.is-active span:nth-child(3) {
        top: 21px;
        transform: rotate(-135deg);
    }

    /* SP News Section specific to TOP */
    .sp-news-section {
        display: block;
        margin-top: 60px; /* clear the 60px absolute header */
        padding: 20px 60px 10px 15px; /* Right padding 60px to avoid hamburger overlap */
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(5px);
        width: 100%;
        position: relative;
        z-index: 1000;
    }

    .sp-news-section .search-label {
        font-size: 14px;
        margin-bottom: 10px;
    }

    /* SP Advanced Search specific to TOP */
    .sp-advanced-search {
        display: block;
        margin-top: 60px; /* clear the 60px absolute header */
        padding: 10px 60px 15px 15px; /* Right padding 60px to avoid hamburger overlap */
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(5px);
        border-bottom: 1px solid #ddd;
        width: 100%;
        position: sticky;
        top: 0;
        z-index: 1001;
    }

    .sp-news-section + .sp-advanced-search {
        margin-top: 0;
    }
    .sp-search-flex {
        display: flex;
        gap: 10px;
        margin-bottom: 10px;
        margin-right: 10px;
    }
    .sp-search-flex .search-item {
        flex: 1;
    }
    .sp-search-flex select {
        width: 100%;
        font-size: 13px;
    }
    .sp-color-search {
        display: flex;
        align-items: center;
        gap: 8px;
    }
    .sp-color-label {
        font-size: 11px;
        font-weight: bold;
        margin-bottom: 0 !important;
        border-bottom: none !important;
        white-space: nowrap;
    }
    .sp-color-dots {
        display: flex;
        flex-wrap: wrap;
        gap: 12px;
    }
    .sp-menu-social {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-top: 40px;
    }
    .sp-menu-social img {
        width: 40px;
    }

    /* SP Menu Overlay */
    .sp-menu-overlay {
        display: block;
        position: fixed;
        top: 0; /* Cover full screen */
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(255,255,255,0.98);
        z-index: 1004; /* Below advanced search 1001, wait! We need it above search. Increase to 1004 is already there */
        transform: translateX(100%);
        transition: transform 0.3s ease-in-out;
        overflow-y: auto;
        padding: 80px 30px 30px; /* Top padding to clear fixed hamburger */
    }

    .sp-menu-overlay.is-active {
        transform: translateX(0);
    }

    .sp-menu-list {
        list-style: none;
        padding: 0;
        margin: 0;
        text-align: center;
    }

    .sp-menu-list li {
        margin-bottom: 20px;
    }

    .sp-menu-list li a {
        font-size: 20px;
        font-family: "Oswald", sans-serif;
        color: #333;
        text-decoration: none;
        display: block;
        padding: 10px;
    }

    /* Adjust content padding for fixed header and side margins */
    .l_wrap {
        padding: 80px 10px 0 10px;
        margin-left: 0;
    }
    
    .home .l_wrap,
    .front-page .l_wrap,
    .archive .l_wrap,
    .search .l_wrap,
    .blog .l_wrap {
        padding-top: 20px !important;
    }

    /* Content Area styling */
    .content-container {
        padding: 30px 10px !important;
    }

    /* Typography scale down */
    h2, .unified-h2 {
        font-size: 30px !important;
        padding-bottom: 10px;
    }

    h3, .unified-h3 {
        font-size: 18px !important;
    }

    /* Grids to 2 Columns */
    ul.gallery > li {
        width: calc(50% - 10px) !important;
    }
    
    ul.workList > li {
        width: 100% !important;
    }
    
    .book-shelf-row {
        margin-top: 15px;
        justify-content: center;
    }

    /* Enlarge Gallery Modal for SP */
    .modal.is-gallery-modal .modal-content {
        width: 85% !important;
        max-width: 85% !important;
    }
    .modal.is-gallery-modal .modal-image-container.swiper .swiper-slide img {
        width: 100%;
        max-height: 80vh;
        object-fit: contain;
    }
}

/* ==========================================================================
   New Icon
   ========================================================================== */
.cover-image, .blog-item-thumb, .gallery__photo {
    position: relative;
}

.newicon {  
  display: inline-block;
  position: absolute;
  top: -6px;
  left: 10px;
  margin: 0;
  padding: 10px 0 7px;
  z-index: 2;
  width: 40px;
  text-align: center;
  color: white;
  font-family: sans-serif;
  font-size: 13px;
  font-weight: bold;
  background: #ff78aa;
  border-radius: 0 2px 0 0;
}

.newicon:before {
  position: absolute;
  content: '';
  top: 0;
  right: -5px;
  border: none;
  border-bottom: solid 6px #d85c8b;
  border-right: solid 5px transparent;
}

.newicon:after {
  content: '';
  position: absolute;
  left: 0;
  top: 100%;
  height: 0;
  width: 0;
  border-left: 20px solid transparent;
  border-right: 20px solid transparent;
  border-top: 10px solid #ff78aa;
}

/* ==========================================================================
   Widget Areas (Google AdSense)
   ========================================================================== */
.post-bottom-widgets {
    margin-top: 40px;
}

.before-footer-widgets {
    width: 100%;
    margin-top: 20px;
}

.right-floating-widgets {
    position: fixed;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    width: 160px; /* Standard wide skyscraper width */
    z-index: 900;
}

@media screen and (max-width: 1200px) {
    .right-floating-widgets {
        display: none !important;
    }
}

/* ==========================================================================
   About Page - Terms of Service
   ========================================================================== */
.table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 20px;
}

.tos-table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    font-size: 15px;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.tos-table th, .tos-table td {
    border: 1px solid #ddd;
    padding: 15px;
    text-align: left;
    line-height: 1.6;
}

.tos-table thead th {
    background-color: #2e558f;
    color: #fff;
    text-align: center;
    font-weight: bold;
}

.tos-table tbody th {
    background-color: #f7f9fc;
    font-weight: bold;
    color: #333;
    width: 25%;
}

.tos-credit-box {
    /* Set only standard spacing since the white box design was removed */
    margin-bottom: 10px;
    margin-top: 20px;
}

.tos-credit-box h4 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #e1898b;
    font-size: 17px;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
}

.tos-credit-box ul {
    margin-bottom: 0;
}

.tos-list li,
.tos-credit-box ul li {
    margin-bottom: 10px;
    line-height: 1.6;
}

