:root {
    --color-main: #00475b;
    --color-main-light: #006d8a;
    --color-accent: #86dd7b;
    --color-text: #4a5457;
    --color-text-light: #666;
    --color-bg: #fdfdfd;
    --color-bg-gray: #f5f7fa;
    --font-base: "Zen Kaku Gothic New", sans-serif;
    --container-width: 1200px;
    --header-height: 80px;
}

@import url("features.css");

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-base);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s, opacity 0.3s;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

.container {
    max-width: 95%;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 120px 0;
    padding-bottom: 300px;
}

.section--gray {
    background-color: var(--color-bg-gray);
}

.section--bg-1 {
    background-color: #fdfdfd;
}

.section--bg-2 {
    background-color: #f6f7fa;
}

.section__header {
    text-align: center;
    margin-bottom: 60px;
}

.section__title {
    font-size: 2rem;
    color: var(--color-main);
    margin-bottom: 10px;
    letter-spacing: 0.05em;
}

.section__subtitle {
    font-size: 1rem;
    color: var(--color-main-light);
    opacity: 0.7;
    letter-spacing: 0.1em;
    font-weight: 700;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    text-align: center;
    transition: all 0.3s;
}

.btn--primary {
    background-color: var(--color-main);
    color: #fff;
}

.btn--primary:hover {
    background-color: var(--color-main-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 71, 91, 0.3);
}

.btn--secondary {
    border: 1px solid var(--color-main);
    color: var(--color-main);
}

.btn--secondary:hover {
    background-color: var(--color-main);
    color: #fff;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.header__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 40px;
}

.header__logo a {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.header__logo-text {
    font-size: 1.25rem;
    color: var(--color-main);
    font-weight: 700;
}

.header__logo-sub {
    font-size: 0.75rem;
    color: var(--color-text-light);
    letter-spacing: 0.05em;
}

.header__nav {
    display: none;
}

@media (min-width: 768px) {
    .header__nav {
        display: block;
        position: static;
        background: none;
        width: auto;
        height: auto;
        padding: 0;
        overflow: visible;
    }
}

@media (max-width: 767px) {
    .header__nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: #fff;
        padding: 80px 0 40px;
        overflow-y: auto;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        opacity: 0;
        visibility: hidden;
        z-index: 999;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
    }



    .header__nav.active {
        opacity: 1;
        visibility: visible;
    }

    .header__list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        width: 100%;
    }

    .header__link {
        font-size: 1.1rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        text-align: left;
        padding: 20px 20px 20px 60px !important;
        /* Increased padding-left to 60px */
        padding-left: 60px !important;
        border-bottom: 1px solid #eee;
        color: var(--color-main);
        font-weight: 700;
    }

    .header__link:hover {
        background-color: #f9f9f9;
    }

    .header__item {
        width: 100%;
    }

    .header__item--cta {
        margin-top: 20px;
        text-align: center;
        padding: 0 20px;
        border-bottom: none;
    }

    .header__item--cta .btn {
        width: 100%;
        background-color: var(--color-main);
        color: #fff;
    }

    /* Mobile Mega Menu Handling */
    .has-mega-menu {
        position: relative;
    }

    .has-mega-menu>.header__link {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        position: relative;
        /* Ensure context for absolute arrow */
    }

    /* Remove previous pseudo-element arrow */
    .has-mega-menu>.header__link::after {
        display: none;
    }

    .arrow {
        position: absolute;
        left: 20px;
        /* Position in padding area */
        width: 32px;
        height: 32px;
        flex: 0 0 auto;
        transition: transform .3s ease;
        transform-origin: 50% 50%;
        transform: rotate(0deg);
        /* Closed: Right */
    }

    .has-mega-menu.active .arrow {
        transform: rotate(90deg);
        /* Open: Down */
    }

    .has-mega-menu .mega-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        width: 100%;
        box-shadow: none;
        border-top: none;
        padding: 0;
        background-color: #f5f7fa;
        /* Light gray for contrast */
        display: none;
        /* Hidden by default, toggled by JS */
    }

    .has-mega-menu.active .mega-menu {
        display: block;
    }

    .mega-menu__inner {
        flex-direction: column;
        padding: 0;
    }

    .mega-menu__col {
        padding: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
    }

    .mega-menu__col:last-child {
        border-bottom: none;
    }

    .mega-menu__title {
        color: var(--color-main);
        font-size: 0.9rem;
        margin: 15px 40px 5px;
        /* Aligned with link padding */
        padding-bottom: 0;
        border-bottom: none;
        display: block;
        opacity: 0.7;
    }

    .mega-menu__list li {
        margin-bottom: 0;
    }

    .mega-menu__list a {
        color: var(--color-text);
        padding: 15px 40px 15px 70px;
        /* Increased padding-left to 70px */
        /* Indented */
        display: block;
        font-size: 1rem;
        position: relative;
        border-radius: 12px;
        /* Updated border-radius */
    }

    .mega-menu__list a::before {
        content: '→';
        position: absolute;
        left: 40px;
        /* Aligned */
        top: 50%;
        transform: translateY(-50%);
        font-size: 0.8rem;
        color: var(--color-main);
        opacity: 0.7;
    }

    .mega-menu__list a:hover {
        /* background-color: #eee; Removed to let animation handle bg */
        /* color: var(--color-main); Removed as requested */
        /* padding-left: 60px; Removed as requested */
        animation: gradation 1s forwards;
    }

    /* Keyframes moved to global scope */

    .header__hamburger {
        display: block;
        width: 30px;
        height: 24px;
        position: relative;
        cursor: pointer;
        background: none;
        border: none;
        z-index: 1001;
    }

    .header__hamburger span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--color-main);
        position: absolute;
        transition: all 0.3s;
        border-radius: 2px;
    }

    /* Change hamburger color to white when menu is active if needed, 
       but the button is outside the nav container usually. 
       Wait, the button is fixed? No, it's in header__inner.
       Header background is white. Nav covers it. 
       We need to make sure hamburger is visible on top of blue nav. */

    .header__nav.active~.header__hamburger span {
        background-color: var(--color-main);
        /* Keep dark on white bg */
    }

    .header__hamburger span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--color-main);
        position: absolute;
        transition: all 0.3s;
        border-radius: 2px;
    }

    .header__hamburger span:nth-child(1) {
        top: 0;
    }

    .header__hamburger span:nth-child(2) {
        top: 11px;
    }

    .header__hamburger span:nth-child(3) {
        bottom: 0;
    }

    .header__hamburger.active span:nth-child(1) {
        transform: rotate(45deg);
        top: 11px;
    }

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

    .header__hamburger.active span:nth-child(3) {
        transform: rotate(-45deg);
        bottom: 11px;
    }
}

@media (min-width: 768px) {
    .header__hamburger {
        display: none;
    }

    /* Hide arrow on desktop */
    .arrow {
        display: none;
    }
}

.header__list {
    display: flex;
    align-items: center;
    gap: 30px;
}

.header__link {
    font-weight: 500;
    position: relative;
    padding: 10px 0;
}

.header__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--color-main);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s;
}

.header__link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Mega Menu */
.has-mega-menu:not([data-mega-managed]):hover .mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mega-menu {
    position: absolute;
    top: var(--header-height);
    left: 0;
    width: 100%;
    background-color: #fff;
    border-top: 1px solid #eee;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    padding: 40px 0;
}

.mega-menu__inner {
    max-width: var(--container-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
}

.mega-menu__col {
    flex: 1;
    padding: 0 20px;
    border-right: 1px solid #eee;
}

.mega-menu__col:last-child {
    border-right: none;
}

.mega-menu__title {
    font-size: 1.1rem;
    color: var(--color-main);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--color-main);
    display: inline-block;
}

.mega-menu__list li {
    margin-bottom: 10px;
}

.mega-menu__list a {
    font-size: 0.95rem;
    color: var(--color-text);
    display: block;
    /* Ensure full width */
    padding: 10px 15px 10px 30px;
    /* Increased left padding for arrow */
    /* Add padding for better click area and look */
    border-radius: 12px;
    /* Rounded corners */
    transition: all 0.3s ease;
    /* Smooth transition for non-animated properties */
    position: relative;
}

.mega-menu__list a::before {
    content: '→';
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.8rem;
    color: var(--color-main);
    opacity: 0.7;
}

.mega-menu__list a:hover {
    /* color: var(--color-main); Removed */
    /* padding-left: 5px; Removed */
    animation: gradation 1s forwards;
}

@keyframes gradation {
    0% {
        background: #e1f7fb;
    }

    100% {
        background: #a2c2cb;
    }
}

/* Hero */
.hero {
    position: relative;
    height: 110vh;
    /* Increased from 100vh by 10% */
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-top: var(--header-height);
    /* Ensure padding at bottom for cards not to overlap text too much if responsive */
    padding-bottom: 100px;
}

.hero__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3)), url("../assets/images/top.png") no-repeat center center/cover;
    background-size: cover;
    background-position: center;
    z-index: -1;
    animation: zoomIn 20s linear infinite alternate;
}

@keyframes zoomIn {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.1);
    }
}

.hero__content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--color-text);
    background-color: rgba(0, 71, 91, 0.3);
    padding: 60px;
    border-radius: 4px;
    max-width: 1000px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.hero__title {
    font-size: clamp(1.2rem, 5vw, 4.5rem);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 20px;
    color: var(--color-main);
    font-family: 'Zen Kaku Gothic New', sans-serif;
    white-space: nowrap;
}

.hero__title-line {
    display: block;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1s forwards;
    color: rgba(255, 255, 255, 1);
}

.hero__title-line:nth-child(2) {
    animation-delay: 0.3s;
}

.hero__text {
    font-size: clamp(0.7rem, 2.5vw, 1.2rem);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1s forwards 0.6s;
    color: rgba(255, 255, 255, 1);
    white-space: nowrap;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero__scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    animation: bounce 2s infinite;
}

.hero__scroll::after {
    content: '';
    display: block;
    width: 1px;
    height: 40px;
    background-color: #fff;
    margin: 10px auto 0;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translate(-50%, 0);
    }

    40% {
        transform: translate(-50%, -10px);
    }

    60% {
        transform: translate(-50%, -5px);
    }
}

/* Feature Card Colors */
.feature-card--outpatient {
    border-bottom: 4px solid #00475b;
}

.feature-card--inpatient {
    border-bottom: 4px solid #c2185b;
}

.feature-card--homecare {
    border-bottom: 4px solid #2e7d32;
}

.feature-card--checkup {
    border-bottom: 4px solid #ef6c00;
}

.feature-card--vaccine {
    border-bottom: 4px solid #7b1fa2;
}

/* Important News */
.news-important {
    background-color: #fce4ec;
    padding: 30px 0 20px;
    /* Increase top padding for label space */
    position: relative;
    z-index: 5;
    /* NOTE: Do NOT add overflow:hidden here — the label needs to overflow upward */
}

.news-important .container {
    position: relative;
    /* Context for absolute label */
    background-color: transparent !important;
    /* Force transparent */
    /* NOTE: Do NOT add overflow:hidden here — the label needs to overflow upward */
}

/* Ensure the dynamically loaded container respects parent bounds */
#js-load-important {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

.news-important__inner {
    display: flex;
    align-items: center;
    /* Center Vertically */
    justify-content: flex-start;
    /* Align left */
    gap: 20px;
    padding-left: 220px;
    /* Space if label was inline, but it's absolute now. */
    overflow: hidden;
    /* Prevent content from spilling out */
    box-sizing: border-box;
}

.news-important__label {
    position: absolute;
    top: -39px;
    /* ▲ ラベル全体の縦位置 */
    left: 33px;
    /* ▲ ラベル全体の横位置 */
    /* ▼ 画像サイズ（固定） */
    width: 180px;
    /* ▲ 画像の横幅 */
    height: 70px;
    /* ▲ 画像の高さ */
    display: flex;
    align-items: center;
    /*justify-content: center;*/
    /* ▼ テキスト位置の微調整（上/右/下/左）画像サイズには影響しません */
    padding: 5px 0px 10px 20px;
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    /* ▲ テキストサイズ */
    line-height: 1.4;
    z-index: 2;
    background: url(../assets/images/siori.png) no-repeat center center;
    background-size: 100% 100%;
}

.news-important__list {
    display: flex;
    flex-direction: column;
    /* Stack vertically */
    gap: 10px;
    /* Adjust gap for vertical stack */
    width: 100%;
    min-width: 0;
    /* Allow flex child to shrink below content size */
    overflow: hidden;
    /* Ensure list respects parent bounds */
}

.news-important__list li {
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px dashed rgba(194, 24, 91, 0.2);
    padding-bottom: 5px;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

.news-important__link {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    min-width: 0;
}

/* Keep space for the excerpt even when the title is long. */
.news-important__title {
    display: block;
    min-width: 0;
    flex: 0 1 auto;
    max-width: 50%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Important News Body (Fill remaining space) */
.news-important__body {
    flex: 1;
    min-width: 0;
    /* Critical: allows flex child to shrink below content size */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: inherit;
    padding-left: 15px;
    border-left: 1px solid rgba(255, 255, 255, 0.5);
}

.news-important__list time {
    flex-shrink: 0;
    width: 100px;
    text-align: left;
}

@media (max-width: 767px) {
    .news-important__inner {
        flex-direction: column;
        align-items: stretch;
        padding-left: 0;
        padding-top: 60px;
    }

    .news-important__list li {
        flex-direction: column;
        align-items: stretch;
        gap: 5px;
        font-size: 0.8rem;
    }

    .news-important__link {
        display: block;
        flex: none;
    }

    .news-important__title {
        flex: none;
        /* Reset flex shorthand for mobile */
        width: 100%;
        max-width: 100%;
        display: block;
    }

    .news-important__body {
        display: none;
    }

    .news-important__list time {
        font-size: 0.8rem;
        margin-bottom: 0;
    }
}

.news-important__list time {
    font-weight: 700;
    color: #c2185b;
}

.news-important__list a {
    text-decoration: underline;
}

/* News */
/* Full Width Container Override */
.news .container {
    max-width: 90%;
    padding: 0 40px;
    /* Ensure generic padding if container usually has 20 */
}

/* 3 Column Split Layout */
.news-container-split {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    max-width: 100%;
    margin: 0 auto;
}

.news-col {
    display: flex;
    flex-direction: column;
}

/* Responsive adjustments for News */
@media (max-width: 900px) {
    .news-container-split {
        grid-template-columns: 1fr;
        /* Stack vertically on tablet/mobile */
        gap: 40px;
    }
}



.news-col-left {
    display: flex;
    flex-direction: column;
}

.news-col-right {
    display: flex;
    flex-direction: column;
}

.news-col-title {
    font-size: 1.25rem;
    color: var(--color-main);
    margin-bottom: 20px;
    padding-bottom: 13px;
    border-bottom: 2px solid #eee;
    font-weight: 700;
}

/* Clean up old tab styles if they are no longer used, or keep them just in case. 
   Removing them to keep file clean as requested structure removed tabs. */
/* Simple list styles for news items in columns */
.news-simple-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 20px;
}

.news-simple-item,
.news-simple-list li {
    display: flex;
    flex-direction: column;
    padding: 2px 0;
    border-bottom: 1px solid #ddd;
    gap: 5px;
}

.news-simple-date {
    font-family: 'Lato', sans-serif;
    color: var(--color-text-light);
    font-weight: 700;
    font-size: 0.8rem;
}

.news-simple-link {
    font-size: 0.85rem;
    color: var(--color-text);
    transition: color 0.3s;
}

.news-simple-link:hover {
    color: var(--color-main);
    text-decoration: none;
}

.news__list {
    margin: 0 0 30px;
    /* Remove auto margins and set bottom margin */
    max-width: none;
    /* Reset max-width */
}

/* Tab Button Styles */
.news__tab {
    background: none;
    border: none;

    /* Match Title Typo */
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-text-light);
    /* Inactive color */

    cursor: pointer;
    padding: 0 0 15px 0;
    /* Match title padding-bottom */
    margin-bottom: -2px;
    /* Overlap container border */
    border-bottom: 2px solid transparent;
    transition: all 0.3s;
    font-family: var(--font-base);
    margin-right: 0;
    /* Reset */
}

.news__tab.active,
.news__tab:hover {
    color: var(--color-main);
    /* Active Color */
    border-bottom-color: var(--color-main);
    /* Active Border */
}

.news__item {
    display: flex;
    align-items: center;
    padding: 15px 0;
    /* Match substitute-list padding */
    border-bottom: 1px dashed #ddd;
    /* Match border */
    gap: 15px;
    /* Match gap */
    font-size: 0.95rem;
    /* Match font size */
    transition: background-color 0.3s;
}

.news__item:hover {
    background-color: #e6f4f7;
    /* More visible light highlighted color */
}

/* 日付のスタイル修正 */
.news__date {
    font-family: 'Lato', sans-serif;
    color: var(--color-text-light);
    font-weight: 700;
    font-size: 0.8rem;
    /* リクエスト通り変更 */
    margin-right: 0;
}

/* タグのスタイル（変更なし、確認用） */
.news__tag {
    font-size: 0.8rem;
    padding: 4px 12px;
    background-color: #eee;
    color: #666;
    border-radius: 4px;
    font-weight: 700;
    min-width: 60px;
    text-align: center;
}

.news__tag--important {
    background-color: #ffebee;
    color: #d32f2f;
}

.news__link {
    font-weight: 500;
    display: block;
    /* ブロック要素として幅を持たせる */
    width: 100%;
}

.news__link:hover {
    text-decoration: none;
    color: var(--color-main);
}

.news__more {
    text-align: left;
    /* Align button to left */
    margin-top: auto;
    /* Push to bottom if needed */
}

/* Substitute List Styles */
.substitute-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.substitute-list li {
    display: flex;
    flex-direction: column;
    /* Stack like left column */
    align-items: flex-start;
    padding: 15px 0;
    border-bottom: 1px dashed #ddd;
    gap: 5px;
    font-size: 0.95rem;
}

.substitute-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.substitute-list time {
    font-family: 'Lato', sans-serif;
    color: var(--color-text-light);
    font-weight: 700;
    font-size: 0.8rem;
    /* Match Left column date size */
    /* Remove min-width if not needed in stacked layout, or keep for alignment if side-by-side. 
       In stacked meta (date + label), they are side-by-side. 
       Left column removed margin-right: 0. 
       Let's keep min-width for alignment consistency between meta items if desired, but left column doesn't have it anymore */
    /* min-width: 90px; Removed to match left column natural flow */
}

.substitute-label {
    font-size: 0.8rem;
    padding: 4px 12px;
    border-radius: 4px;
    font-weight: 700;
    min-width: 60px;
    text-align: center;
}

.substitute-label:contains("休診") {
    /* This pseudo-selector doesn't exist in standard CSS, usually handled by class */
    background-color: #ffebee;
    color: #d32f2f;
}

/* So we use classes or nth-child logic if we can't edit HTML per item class easily yet. 
   But I can edit HTML if needed. For now rely on simple styling or default.
   Actually I can just style generic spans or add specific classes in HTML.
   I'll assume generic for now and add a rule for the specific text content isn't possible in CSS directly without :has or JS.
   Let's just style general labels for now.
*/
.substitute-list li:nth-child(2n+1) .substitute-label {
    /* Alternating logic or just generic style */
    background-color: #eee;
    color: #555;
}

.substitute-text {
    flex: 1;
}

/* Specific styling for the 'Important' items inside the list */
.news__item--important {
    background-color: #fff9fc;
}

.news__tag--important {
    background-color: #ffebee;
    color: #d32f2f;
}

@media (max-width: 767px) {

    /* Mobile font reductions (Approx 20% smaller) - Moved to end of section to ensure cascade */
    .news__tab {
        font-size: 0.8rem !important;
        /* Adding important just in case, or relying on cascade */
    }

    .news__item {
        font-size: 0.75rem !important;
    }

    .news__date,
    .substitute-date,
    .news__tag {
        font-size: 0.6rem !important;
    }

    .substitute-meta {
        font-size: 0.8rem !important;
    }

    .substitute-label {
        font-size: 0.6rem !important;
    }

    .substitute-text {
        font-size: 0.75rem !important;
    }

    .news-col-title {
        font-size: 0.8rem !important;
    }

    .container {
        max-width: 100% !important;
        padding: 0 20px !important;
        /* Ensure generic padding if container usually has 20 */
    }
}



.hero {
    height: auto;
    min-height: 100vh;
    padding-bottom: 20px;
    flex-direction: column;
    justify-content: center;
}

.features__container {
    position: static;
    padding: 20px;
    background: transparent;
    width: 100%;
}

.hero__content {
    margin-top: 40px;
    margin-bottom: 40px;
}


/* Wrapper for reordering sections */
.top-sections-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
}

@media (min-width: 768px) {
    .hero {
        order: 1;
    }

    /* Features inside Hero for PC */
    .features-section-wrapper {
        order: 3;
        margin-top: 0px;
        /* Pull up to overlap Hero */
        position: relative;
        z-index: 20;
    }

    .news-important {
        order: 2;
    }
}

@media (max-width: 767px) {
    .hero {
        order: 1;
        min-height: auto;
        /* Allow auto height on mobile */
    }

    .news-important {
        order: 2;
        margin-top: 40px;
    }

    .features-section-wrapper {
        order: 3;
        margin-top: 0;
        padding-top: 20px;
    }
}

/* Concept Softening */
.section--soft-bg {
    background-color: #f0f8ff;
    border-radius: 0;
}

.concept__inner {
    display: flex;
    align-items: center;
    gap: 60px;
}

.concept__image {
    flex: 1;
    border-radius: 30px;
    box-shadow: 0 15px 40px rgba(0, 40, 50, 0.15);
    overflow: hidden;
}

.concept__content {
    flex: 1;
}




/* Mobile: Horizontal Scroll (Disable Orbit) */


/* Concept/Departments Wrapper */
.concept-group.departments-group {
    padding: 60px 0;
    margin: 60px 0;
}

.concept-group.departments-group .section__title,
.concept-group.departments-group .section__subtitle {
    color: var(--color-main);
}

/* Departments Broken Grid Layout */
.concept__content.dept-container {
    max-width: 1500px;
    margin: 0 auto 150px;
    padding: 0 30px;
    display: flex;
    flex-direction: column;
    gap: 140px;
}

.dept-item {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.dept-item--left {
    align-items: flex-start;
}

.dept-item--right {
    align-items: flex-end;
}

.dept-title {
    font-size: 36px;
    font-weight: 400;
    letter-spacing: 0.05em;
    margin: 0 0 20px 0;
    line-height: 1;
    position: relative;
    z-index: 10;
    color: #333333;
}

.dept-layout-box {
    position: relative;
    width: 90%;
    max-width: 900px;
    padding: 40px 0;
    box-sizing: border-box;
    min-height: 220px;
}

.dept-item--left .dept-layout-box {
    margin-left: 50px;
}

.dept-item--right .dept-layout-box {
    margin-right: 50px;
}

.dept-img-box {
    position: absolute;
    width: 180px;
    height: 180px;
    background-color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-sizing: border-box;
    box-shadow: none;
    z-index: 4;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.dept-img-box img {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.dept-glass-panel {
    position: absolute;
    background-color: var(--accent-color);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-sizing: border-box;
    border: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 2;
    width: 40%;
}

.dept-item--left .dept-glass-panel {
    top: -30px;
    bottom: -40px;
    left: 0;
    right: auto;
}

.dept-item--right .dept-glass-panel {
    top: -30px;
    bottom: -40px;
    right: 0;
    left: auto;
}

.dept-desc {
    position: relative;
    z-index: 3;
    margin: 0;
    font-size: 17px;
    line-height: 1.8;
    color: #333333;
    width: 90%;
}

.dept-item--left .dept-desc {
    margin-left: 60px;
}

.dept-item--right .dept-desc {
    margin-left: auto;
    margin-right: 60px;
}

.dept-item--left .dept-img-box {
    bottom: -40%;
    left: 30%;
    right: auto;
}

.dept-item--right .dept-img-box {
    bottom: -40%;
    right: 30%;
    left: auto;
}

.dept-detail-link {
    position: absolute;
    font-size: 15px;
    color: var(--color-main);
    text-decoration: none;
    letter-spacing: 0.1em;
    z-index: 5;
    display: inline-block;
    border-bottom: 1px solid transparent;
    transition: color 0.3s ease, border-color 0.3s ease, opacity 0.3s ease;
}

.dept-detail-link .arrow {
    display: inline-block;
    margin-left: 5px;
    transition: transform 0.3s ease;
}

.dept-detail-link:hover {
    opacity: 0.7;
    border-color: var(--color-main);
}

.dept-detail-link:hover .arrow {
    transform: translateX(5px);
}

.dept-item--left .dept-detail-link {
    bottom: -5%;
    left: 3%;
}

.dept-item--right .dept-detail-link {
    bottom: -5%;
    right: 3%;
}

.dept-layout-box:has(.dept-detail-link:hover) .dept-img-box {
    transform: scale(1.08);
}

@media (max-width: 768px) {
    .dept-container {
        gap: 120px;
        padding: 0 15px;
    }

    .dept-title {
        font-size: 28px;
        text-align: left;
        width: auto;
    }

    .dept-item--left .dept-layout-box,
    .dept-item--right .dept-layout-box {
        width: 100%;
        margin: 0;
        padding: 20px 0;
    }

    .dept-glass-panel {
        width: 80% !important;
    }

    .dept-item--left .dept-glass-panel {
        left: 5%;
        right: auto;
        max-width: 50%;
    }

    .dept-item--right .dept-glass-panel {
        right: 5%;
        left: auto;
        max-width: 50%;
    }

    .dept-item--left .dept-desc,
    .dept-item--right .dept-desc {
        width: 95%;
    }

    .dept-item--left .dept-desc {
        margin-left: 10px;
    }

    .dept-item--right .dept-desc {
        margin-right: 10px;
        margin-left: auto;
    }

    .dept-item--left .dept-img-box,
    .dept-item--right .dept-img-box {
        width: 120px;
        height: 120px;
        padding: 0;
    }

    .dept-item--left .dept-img-box {
        bottom: -25%;
        left: 45%;
        right: auto;
    }

    .dept-item--right .dept-img-box {
        bottom: -25%;
        right: 45%;
        left: auto;
    }

    .dept-item--left .dept-detail-link,
    .dept-item--right .dept-detail-link {
        font-size: 14px;
        bottom: -10%;
    }

    .dept-item--left .dept-detail-link {
        left: 10%;
    }

    .dept-item--right .dept-detail-link {
        right: 10%;
    }
}

/* General Softening */
.btn {
    border-radius: 50px;
}

.news__item {
    display: flex;
    flex-direction: column;
    /* 縦並びにする */
    align-items: flex-start;
    /* 左揃え */
    padding: 15px 0;
    border-bottom: 1px dashed #ddd;
    gap: 5px;
    /* 上下要素の間隔 */
    font-size: 0.95rem;
    transition: background-color 0.3s;
}

.news__meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.section__title {
    font-weight: 500;
    /* Softer font weight */
}


/* Access */
.access__inner {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.access__map {
    flex: 1;
    min-width: 300px;
    border-radius: 10px;
    overflow: hidden;
}

.access__info {
    flex: 1;
    min-width: 300px;
}

.access__name {
    font-size: 1.5rem;
    color: var(--color-main);
    margin-bottom: 10px;
}

.access__address,
.access__tel {
    margin-bottom: 10px;
}

/* Footer */
.footer {
    background-color: var(--color-main);
    color: #fff;
    padding: 60px 0 20px;
}

.footer__inner {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 40px;
}

.footer__logo {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.footer__links {
    display: flex;
    gap: 60px;
}

.footer__list li {
    margin-bottom: 10px;
}

.footer__list a {
    opacity: 0.8;
}

.footer__list a:hover {
    opacity: 1;
    text-decoration: underline;
}

.footer__copyright {
    text-align: center;
    font-size: 0.8rem;
    opacity: 0.6;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
}

/* Responsive */
@media (max-width: 767px) {
    .header__inner {
        padding: 0 20px;
    }

    /* .hero__title font-size is handled by clamp() */

    .concept__inner {
        flex-direction: column;
    }

    .concept__image {
        width: 100%;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    }

    .footer__inner {
        flex-direction: column;
    }

    .footer__links {
        flex-direction: column;
        gap: 20px;
    }
}

/* Page Header */
.page-header {
    background-color: var(--color-bg-gray);
    padding: 120px 0 60px;
    text-align: center;
}

.page-header__title {
    font-size: 2rem;
    color: var(--color-main);
}

/* =========================================
   Sub Page Styles
   ========================================= */

/* Page Hero */
.page-hero {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    overflow: hidden;
}

.page-hero__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.page-hero__bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
}

.page-hero__content {
    position: relative;
    z-index: 1;
}

.page-hero__icon img {
    width: 60px;
    height: 60px;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
}

.page-hero__title {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    margin-bottom: 0.5rem;
}

.page-hero__subtitle {
    font-size: 1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0.9;
}

/* Breadcrumb */
.breadcrumb {
    background-color: #f5f5f5;
    padding: 1rem 0;
    font-size: 0.9rem;
}

.breadcrumb__list {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
}

.breadcrumb__list li {
    display: flex;
    align-items: center;
}

.breadcrumb__list li:not(:last-child)::after {
    content: '>';
    margin: 0 0.5rem;
    color: #999;
}

.breadcrumb__list a {
    color: #666;
    text-decoration: none;
}

.breadcrumb__list a:hover {
    text-decoration: underline;
}

/* Intro Section */
.intro-section {
    padding: 4rem 0;
}

.intro-text {
    margin-bottom: 4rem;
    text-align: center;
}

.intro-text__title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1.5rem;
}

.intro-text__lead {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    font-weight: 500;
}

/* Notice Box */
.notice-box {
    border: 2px solid #ff6b6b;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .notice-box {
        flex-direction: row;
    }
}

.notice-box__header {
    background-color: #ff6b6b;
    color: #fff;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 200px;
}

.notice-box__title {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
}

.notice-box__content {
    padding: 1.5rem;
    flex: 1;
    background-color: #fff;
}

.notice-box__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.notice-box__list li {
    display: flex;
    flex-direction: column;
    margin-bottom: 0.8rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.8rem;
}

.notice-box__list li:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

@media (min-width: 768px) {
    .notice-box__list li {
        flex-direction: row;
        align-items: center;
    }
}

.notice-box__date {
    color: #ff6b6b;
    font-weight: 700;
    margin-right: 1rem;
    font-size: 0.9rem;
    min-width: 100px;
}

.notice-box__link {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.notice-box__link:hover {
    color: #ff6b6b;
}

/* Visitation Info */
.visitation-section {
    padding-top: 0;
}

.visitation-info {
    border-top: 1px dotted #ddd;
    border-bottom: 1px dotted #ddd;
    padding: 2rem 0;
}

.visitation-info__row {
    display: flex;
    flex-direction: column;
    margin-bottom: 1.5rem;
}

.visitation-info__row:last-child {
    margin-bottom: 0;
}

@media (min-width: 768px) {
    .visitation-info__row {
        flex-direction: row;
        align-items: baseline;
    }
}

.visitation-info__row dt {
    font-weight: 700;
    min-width: 150px;
    color: #333;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .visitation-info__row dt {
        margin-bottom: 0;
    }
}

.visitation-info__row dd {
    margin: 0;
    color: #555;
}

.text-link {
    color: #333;
    text-decoration: underline;
    transition: color 0.3s;
}

.text-link:hover {
    color: #0056b3;
}

/* TOC Grid */
.toc-section {
    background-color: #f9f9f9;
}

.section__title--small {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.toc-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .toc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .toc-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.toc-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.toc-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.toc-card__image {
    height: 200px;
    overflow: hidden;
}

.toc-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.toc-card:hover .toc-card__image img {
    transform: scale(1.05);
}

.toc-card__content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.toc-card__title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    color: #333;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.toc-card__desc {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.6;
    margin: 0;
}

/* Sidebar Layout */
.page-layout {
    display: flex;
    padding-top: 60px;
    padding-bottom: 60px;
    align-items: flex-start;
}

/* Modifier for wider layout on symptom pages */
.page-layout-container {
    max-width: 95%;
    /* More full-width as requested */
    width: 1400px;
    /* But capped at reasonable width */
}

.sidebar {
    width: 220px;
    /* Reduced by ~10% from 250px */
    flex-shrink: 0;
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 120px);
    /* Prevent cutoff */
    overflow-y: auto;
    /* Add scrollbar if needed */
}

/* Revamped Section Title */
/* Intro Title */
.symptom-intro__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-main);
    margin: 30px 0 40px;
    /* Top 30px, Bottom 40px to match request */
}

/* Alert Title */
.symptom-alert__title {
    font-weight: 700;
    color: #c62828;
    margin-bottom: 40px;
    /* Updated to 40px */
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Point Title */
.symptom-point__title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-main);
    margin-bottom: 40px;
    /* Updated to 40px */
}

.symptom-section__title {
    font-size: 1.5rem;
    color: var(--color-main);
    margin-top: 60px;
    margin-bottom: 40px;
    /* Updated to 40px */
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Page Title (inside main-content) */
.content-title {
    font-size: 1.8rem;
    color: var(--color-main);
    margin-bottom: 40px;
    /* Updated to 40px */
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

/* Long gray line filling the rest */
/* Line style: Text - (Blue) - (Gap) - (Gray) */
.symptom-section__title::after {
    content: '';
    flex: 1;
    /* Take remaining space */
    height: 2px;
    background: linear-gradient(to right, #4facfe 0, #4facfe 30px, transparent 30px, transparent 45px, #e0e0e0 45px);
    margin-left: 15px;
}

/* Intro Image Styling */
/* Intro Image Styling */
.symptom-intro__image {
    flex: 0 0 45%;
    /* Fixed width of 45% */
    padding: 20px;
    /* Add whitespace around the image */
    display: flex;
    align-items: center;
    justify-content: center;
    /* background-color: #fff; REMOVED to match intro background */
    /* border-radius: 8px; REMOVED */
}

/* Intro Section Container */
.symptom-intro {
    background-color: #fdfdfd;
    border-radius: 12px;
    padding: 0;
    margin-bottom: 60px;
    /* Clearfix for floated children */
    overflow: hidden;
    display: block;
    /* Ensure it's block, not flex */
}

/* Intro Content Styling */
/* Text flows around the floated image */
.symptom-intro__content {
    display: block;
    padding: 30px 0;
    /* Remove side padding to align with left edge */
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Intro Image Styling */
.symptom-intro__image {
    float: right;
    /* Float right to allow text wrapping */
    width: 45%;
    /* Fixed width */
    margin-left: 30px;
    /* Space between text and image */
    margin-bottom: 20px;
    /* Space if text wraps under */
    margin-top: 30px;
    /* Add some top margin to align with text better? */
    margin-right: 30px;
    /* Add right margin for balance? OR padding in parent? */
    display: block;
    padding: 0;
    /* Remove padding, control via margin */
}

/* Remove internal padding of image container if using margin */

/* Ensure image fits */
.symptom-intro__image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

@media (max-width: 768px) {
    .symptom-intro {
        flex-direction: column;
    }

    .symptom-intro__image {
        padding: 20px;
    }
}

.sidebar__nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 100px;
    margin-bottom: 20px;
}

.sidebar__link {
    display: block;
    padding: 3px 0;
    font-size: 0.8rem;
    color: var(--color-text);
    transition: all 0.3s;
    font-weight: 500;
    position: relative;
    padding-left: 15px;
    text-decoration: none;
    /* Ensure no default underline */
}

/* Base icon styled in ::before - Removed '＞' as requested */
.sidebar__link::before {
    content: '';
    position: absolute;
    left: 0;
    color: #999;
    font-size: 0.7rem;
    top: 50%;
    transform: translateY(-50%);
    transition: color 0.3s;
}

/* Hover Animation: Underline drawing from left */
.sidebar__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 15px;
    /* Start text alignment, not covering icon */
    width: 0;
    height: 1px;
    background-color: var(--color-main);
    transition: width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.sidebar__link:hover {
    color: var(--color-main);
}

.sidebar__link:hover::after {
    width: calc(100% - 15px);
    /* Full width minus icon padding */
}

.sidebar__link.active {
    color: #4facfe;
    font-size: medium;
    /* Cyan/Blue specific color */
    font-weight: 700;
    margin-top: 10px;
    margin-bottom: 10px;
}

.sidebar__link.active::before {
    content: '●';
    color: #4facfe;
    font-size: 0.7rem;
}

/* Optional: Keep underline for active state or not? 
   Usually clean to just keep the dot. 
   I will leave the hover effect on active items too for consistency. */

.main-content {
    flex: 1;
    min-width: 0;
    /* Prevent overflow */
}

.content-title {
    font-size: 1.8rem;
    color: var(--color-main);
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

.content-body {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
}

.content-image {
    flex: 0 0 300px;
}

.content-image img {
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.content-text {
    flex: 1;
}

@media (max-width: 768px) {
    .page-layout {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        position: static;
        margin-bottom: 40px;
        display: none;
        /* Hide sidebar on mobile as requested */
    }

    .content-body {
        flex-direction: column;
    }

    .content-image {
        flex: auto;
        width: 100%;
    }
}

/* Symptom Content Styles */
.content-text h3 {
    font-size: 1.4rem;
    color: var(--color-main);
    border-left: 5px solid var(--color-main);
    padding-left: 15px;
    margin-top: 40px;
    margin-bottom: 20px;
    line-height: 1.4;
}

.content-text h3:first-child {
    margin-top: 0;
}

.content-text p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: #444;
}

/* Check List */
.list-check {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
}

.list-check li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 10px;
    font-weight: 700;
    color: var(--color-main);
}

.list-check li::before {
    content: '✔';
    position: absolute;
    left: 0;
    top: 0;
    color: var(--color-accent);
    font-weight: 900;
}

/* Alert Box */
.box-alert {
    background-color: #fff9f9;
    border: 2px solid #ffcccc;
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
}

.box-alert__title {
    color: #c2185b;
    font-weight: 700;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.box-alert__title::before {
    content: '!';
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 24px;
    height: 24px;
    background-color: #c2185b;
    color: #fff;
    border-radius: 50%;
    font-size: 0.9rem;
}

/* -------------------------------------------------- */
/* News Page Styles */
/* -------------------------------------------------- */

.news-page {
    padding-top: 120px;
    /* Header space */
    padding-bottom: 80px;
}

.news-container {
    display: flex;
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

@media screen and (min-width: 1280px) {
    .news-container {
        max-width: none;
        margin-left: 50px;
        margin-right: 50px;
        padding: 0;
    }
}

/* Sidebar */
.news-sidebar {
    width: 280px;
    flex-shrink: 0;
}

.sidebar-section {
    margin-bottom: 40px;
}

.sidebar-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-main);
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.category-list li,
.archive-list li {
    margin-bottom: 10px;
}

.category-link,
.archive-link {
    display: flex;
    justify-content: space-between;
    color: var(--color-text);
    transition: color 0.3s;
    cursor: pointer;
}

.category-link:hover,
.category-link.active,
.archive-link:hover,
.archive-link.active {
    color: var(--color-main);
    font-weight: 700;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-link {
    font-size: 0.85rem;
    background-color: #f0f0f0;
    padding: 6px 12px;
    border-radius: 4px;
    color: var(--color-text);
    transition: all 0.2s;
    cursor: pointer;
}

.tag-link:hover,
.tag-link.active {
    background-color: var(--color-main);
    color: #fff;
}

/* Main Content */
.news-main {
    flex-grow: 1;
}

.page-title {
    font-size: 1.8rem;
    color: var(--color-main);
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-top: 1px solid #eee;
}

.news-item {
    display: flex;
    align-items: baseline;
    gap: 30px;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
    transition: background 0.2s, transform 1s cubic-bezier(0.17, 0.84, 0.44, 1), box-shadow 1s cubic-bezier(0.17, 0.84, 0.44, 1);
    transform-origin: center;
    backface-visibility: hidden;
    /* Prevent blur on scale */
}

.news-item:hover {
    background-color: #f9f9f9;
    transform: scale(1.02);
    box-shadow: rgba(0, 0, 0, 0.15) 0px 5px 15px;
    z-index: 1;
    /* Ensure it floats above others */
    position: relative;
    /* Needed for z-index */
}

.news-date {
    font-family: 'Lato', sans-serif;
    font-weight: 700;
    color: var(--color-text-light);
    font-size: 0.9rem;
    width: 100px;
    flex-shrink: 0;
    padding-left: 20px;
}

.news-content {
    flex-grow: 1;
}

.news-link {
    color: var(--color-text);
    font-size: 1rem;
    display: block;
    text-decoration: none;
    transition: color 0.2s;
}

.news-link:hover {
    color: var(--color-main);
}

.news-label {
    display: inline-block;
    font-size: 0.8rem;
    padding: 2px 8px;
    border: 1px solid var(--color-main);
    color: var(--color-main);
    border-radius: 4px;
    margin-right: 10px;
    background-color: #fff;
}

/* Pagination */
.pagination {
    margin-top: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.page-btn {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid #ddd;
    color: var(--color-text);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.page-btn:hover {
    border-color: var(--color-main);
    color: var(--color-main);
}

.page-btn.active {
    background-color: #ddd;
    border-color: #ddd;
    color: #333;
    cursor: default;
}

.page-info {
    margin-bottom: 20px;
    text-align: right;
    font-family: 'Lato', sans-serif;
    color: #666;
    font-size: 0.9rem;
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .news-container {
        flex-direction: column;
        gap: 40px;
    }

    .news-sidebar {
        width: 100%;
    }

    .news-item {
        flex-direction: column;
        gap: 5px;
    }

    .news-date {
        width: auto;
    }
}

/* File Icon & Layout Helpers */
.news-simple-row {
    display: flex;
    align-items: center;
}

.news-file-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text);
    margin-right: 6px;
    transition: color 0.2s;
}

.news-file-icon:hover {
    color: var(--color-main);
}

/* News Header Links */
.news-col-title {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-bottom: 2px solid var(--color-main);
    width: 120%;
    padding-left: 15px;
    padding-bottom: 5px;
    margin-bottom: 0px;
}

.news-col-title-en {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-main);
    margin-left: 15px;
}

.news-list-link {
    font-size: 0.8rem;
    color: var(--color-text-light);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s;
}

.news-list-link:hover {
    color: var(--color-main);
}

.news-list-arrow {
    width: 6px;
    height: 6px;
    border-top: 1px solid currentColor;
    border-right: 1px solid currentColor;
    transform: rotate(45deg);
    display: inline-block;
    margin-bottom: 1px;
}

/* News Card Design (Reference Style) */
.news-card-item {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid #d4d4d4;
    padding: 0;
    margin-bottom: 0;
    transition: background 0.3s, transform 0.3s ease, box-shadow 0.3s ease;
    width: 120%;
    /* ★ ここでボーダーの長さを指定します（親カラム幅の104%に広がる） */
}

.news-card-item:hover {
    transform: translateY(-2px);
    box-shadow: rgba(0, 0, 0, 0.15) 0px 3px 8px;
    z-index: 1;
    position: relative;
    background-color: rgba(255, 255, 255, 0.4);
    /* Slightly transparent white */
}

.news-card-item:last-child {
    border-bottom: none;
}

.news-card-date {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 80px;
    flex-shrink: 0;
    padding: 15px 0;
    border-bottom: 1px solid #d4d4d4;
    /* To match internal division if wanted, but simpler to keep clean */
    border-bottom: none;
    /* Let parent handle border */
    /* Add a small separator line under year like in reference image? */
}

.news-card-year {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--color-text-light);
    line-height: 1;
    margin-bottom: 5px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 2px;
    width: 60%;
    text-align: center;
}

.news-card-day {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--color-text);
    line-height: 1;
}

.news-card-content {
    flex: 1;
    /* 残りの空間（カード全体 - 日付幅など）をいっぱいに使う */
    min-width: 0;
    /* はみ出し防止 */
    background-color: transparent;
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.news-card-row {
    display: flex;
    align-items: center;
    width: 100%;
}

.news-card-link {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-text);
    text-decoration: none;
    transition: opacity 0.3s;
    line-height: 1.5;
}

.news-card-link:hover {
    opacity: 0.7;
}

/* Adjust file icon vertical align in this new layout */
.news-card-row .news-file-icon {
    display: flex;
    align-items: center;
    margin-right: 10px;
    color: var(--color-text);
}


/* Adjust container splitting for 3 columns on PC */
.news-container-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 1024px) {
    .news-container-split {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Refined News Card Styles for Fixes */

/* 1. Date Layout Fix: Ensure split lines */
.news-card-date {
    /* Already flex-col, center, width 80px */
    /* Ensure no wrapping */
    white-space: nowrap;
}

.news-card-year {
    display: block;
    /* Force new line */
    width: 60%;
    /* Separator width */
    margin: 0 auto 5px auto;
    /* Center */
}

.news-card-day {
    display: block;
    /* Force new line */
}

/* 2. Hover Effect */
.news-card-item {
    cursor: pointer;
    /* Show pointer on whole card */
}

/* Background color change removed on hover as per request */

/* Make sure the link covers the area or behaves well */
.news-card-content {
    transition: background-color 0.2s ease;
}

/* Ensure Title is to the right implies standard flow, which flex-row does. */
/* Just ensuring text alignment is left */
.news-card-link {
    text-align: left;
}


/* 3. Layout Fix: Force Row Direction */
.news-card-item {
    flex-direction: row !important;
    align-items: stretch !important;
}

/* News Detail Header Layout Refactor */
.page-header {
    position: relative;
    /* Context for breadcrumb */
    padding: 60px 20px 40px;
    /* Top padding space for breadcrumb */
    text-align: center;
    /* Center the article header content by default */
    background-color: transparent;
    /* Or whatever default is */
}

.page-breadcrumb {
    position: absolute;
    top: 10px;
    /* Or 0 if flush with top */
    left: 0px;
    /* Left align */
    font-size: 0.8rem;
    color: var(--color-text-light);
    margin: 0;
}

/* Article Header Styles */
.news-article__header-container {
    max-width: 800px;
    margin: 0 auto;
}

.news-article__meta {
    display: flex;
    justify-content: center;
    /* Centered */
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.news-article__date {
    font-family: 'Lato', sans-serif;
    /* Example font */
    color: var(--color-text-light);
    font-weight: 700;
}

.news-label {
    background-color: var(--color-main);
    color: #fff;
    padding: 4px 12px;
    font-size: 0.8rem;
    border-radius: 2px;
}

.news-article__title {
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--color-main);
}

/* News Detail Refinement */

/* 1. Header Alignment & Separator */
.news-article__meta {
    justify-content: flex-start;
    /* Left align */
}

.news-article__title {
    text-align: left;
    margin-bottom: 20px;
}

.news-article__header-container {
    padding-bottom: 40px;
    border-bottom: 1px solid #eee;
    /* Separator */
    margin-bottom: 60px;
    /* Space below separator */
}

/* 2. Sidebar Gap Adjustment */
/* Need to override or ensure .news-container gap */
/* Checking existing css via specificity, usually .news-container is flex */
.news-container {
    gap: 120px;
    /* Requested gap */
    /* Ensure flex property exists, see below check */
}

/* If .news-container is defined earlier, this append overrides it if specificity is equal or higher */


/* 3. Sidebar Font Size & Dropdown */
.sidebar-title {
    font-size: 1.1rem;
    /* Slightly smaller if needed, or keep */
}

.category-list a,
.tag-list a {
    font-size: 0.85rem;
    /* Smaller font as requested */
}

.archive-select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--color-text);
    background-color: #fff;
    cursor: pointer;
}

.archive-select:focus {
    outline: none;
    border-color: var(--color-main);
}

/* News Detail Alignment Fixes */

/* Force Left Align for Header Container */
.news-article__header-container {
    margin-left: 0;
    margin-right: auto;
    /* max-width is 800px, so this aligns it to the left */
}

/* Override Page Header Center Text if needed, though container alignment handles block elements */
.page-header {
    text-align: left;
    /* Align inline content like breadcrumbs too if not absolute */
}

/* Increase spacing for Back Button */
.news-detail-footer {
    margin-top: 80px;
    /* Increased spacing */
    text-align: center;
    /* Keep button centered? User said "separate from id=js-news-detail" */
    /* If user wants button left aligned too? "一覧に戻るボタンを...離して設置" -> implying spacing */
    /* Usually back buttons are centered or left. I'll keep center unless specified, focusing on spacing. */
}

/* Final News Detail Tweaks */

/* 1. Align Header Left (Remove padding from container or shift content) */
.page-header {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Note: max-width 800px on header container might prevent full width if screen is large, but left align fixes that. */


/* 2. Add padding to Body */
.news-detail {
    padding-left: 10px;
    /* "A little" padding */
    padding-right: 10px;
    /* Symmetry */
}

/* 3. Reduce vertical space */
.news-article__header-container {
    margin-bottom: 30px !important;
    /* Reduced from 60px */
    padding-bottom: 20px !important;
    /* Reduced from 40px */
}

/* ==========================================================================
   Responsive Header (<= 1280px)
   ========================================================================== */
@media (max-width: 1280px) {
    .header__inner {
        padding: 0 clamp(15px, 2vw, 40px);
    }

    .header__list {
        gap: clamp(10px, 3.5vw, 30px);
    }

    .header__link {
        font-size: clamp(0.85rem, 1.2vw, 1rem);
    }
}

/* === Page Header Adjustment === */
.page-header {
    padding-top: calc(var(--header-height) + 50px);
    padding-bottom: 40px;
    text-align: center;
}

.page-header__title {
    font-size: 2.2rem;
    color: var(--color-main);
    font-weight: 700;
    letter-spacing: 0.05em;
    margin-bottom: 0;
}

@media (max-width: 767px) {
    .page-header {
        padding-top: calc(var(--header-height) + 30px);
        padding-bottom: 30px;
    }

    .page-header__title {
        font-size: 1.8rem;
    }
}

/* -----------------------------------------------------------------
   Generic Tab / Sticky Note Section Design
   ----------------------------------------------------------------- */
.section-tab-design {
    position: relative;
    padding-top: 50px;
    padding-bottom: 50px;
    /* Background is handled by utility class (e.g. section--bg-2) */
    /* Default variables */
    --tab-bg: #fce4ec;
    --tab-text: #c2185b;
    --tab-fold-color: rgba(0, 0, 0, 0.15);
}

/* 3-box horizontal row layout for News section */
.news-boxes-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    /* Force equal width strictly, preventing squishing */
    gap: 30px;
    max-width: 95%;
    margin: 0 auto;
    padding: 0 20px;
}

.news-boxes-row .news-box {
    max-width: 100%;
    width: 100%;
}

/* Section divider with label sitting on the border */
.news-section-divider {
    position: relative;
    max-width: 95%;
    margin: 0 auto 40px;
    padding: 0 20px;
    /* The horizontal border line */
    border-bottom: 2px solid #ddd;
}

.news-section-divider .section-tab-label {
    /* Position label on the border line */
    position: absolute;
    bottom: -1px;
    /* Sit on top of the border */
    left: 50px;
    transform: translateY(50%);
    z-index: 2;
}

@media (max-width: 1100px) {
    .news-boxes-row {
        grid-template-columns: 1fr;
        gap: 50px;
    }
}

/* Content Container (Transparent) */
.section-tab-design .container {
    background-color: transparent;
    box-shadow: none;
    border-radius: 0;
    padding: 40px 0;
    /* Adjusted padding - remove side padding if it was for the box */
    position: relative;
    position: relative;
    z-index: 1;
}

/* News Box Style (Boxed Layout) */
.section-tab-design .container.news-box {
    padding: 100px 60px;
    /* Increased vertical padding */
    /* Adjust for tab visual */
    margin-top: 30px;
    /* Space for tab to not hit section top edge too hard */
}

/* Pseudo-element strictly for the background so it can be moved individually */
.section-tab-design .container.news-box::before {
    content: "";
    position: absolute;
    top: 75px;
    left: 140px;
    width: 75%;
    height: 60%;
    background-color: #eceef0;
    border-radius: 5px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
    /* Subtle depth */
    z-index: -1;
    /* Place behind the text content */
}

@media (max-width: 767px) {
    .section-tab-design .container.news-box {
        padding: 40px 20px;
    }
}

/* Sticky Note Label (Background Image Based - same structure as .news-important__label) */
.section-tab-label {
    position: absolute;
    top: -43px;
    /* ▲ ラベル全体の縦位置 */
    left: 50px;
    /* ▲ ラベル全体の横位置 */
    /* ▼ 画像サイズ（固定） */
    width: 175px;
    /* ▲ 画像の横幅 */
    height: 70px;
    /* ▲ 画像の高さ */
    display: flex;
    align-items: center;
    /*justify-content: center;*/
    /* ▼ テキスト位置の微調整（上/右/下/左）画像サイズには影響しません */
    padding: 0px 0px 10px 45px;
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    /* ▲ テキストサイズ */
    white-space: nowrap;
    z-index: 2;
    background: url(../assets/images/siori2.png) no-repeat center center;
    background-size: 100% 100%;
}

/* 以下は img+span 構造を使う場合のfallbackスタイル（不要なら削除可） */
.section-tab-label-bg {
    display: none;
    /* background-image方式を使用するため非表示 */
}

.section-tab-label-text {
    position: static;
    /* background-image方式ではテキストはそのまま表示 */
    transform: none;
}



/* Remove CSS Fold Effects */
.section-tab-label::before,
.section-tab-label::after {
    display: none;
    content: none;
}

@media (max-width: 767px) {
    .news-col {
        padding-top: 100px;
    }
}

.news-box {
    position: relative;
}

/* =========================================
   Loading Screen
   ========================================= */
#loading {
    position: fixed;
    inset: 0;
    /* The same soft white as the home hero's opening, so the loader and the drop that follows share one surface. */
    background: radial-gradient(ellipse at 50% 45%, #ffffff 0%, #f4f9f8 62%, #e8f1ef 100%);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#loading.loaded {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* The spinner sits at the exact centre of the screen; on the home page it closes into a ring
   and becomes the water drop (js/home-hero.js). The name stands above it. */
.loading__content {
    position: relative;
    z-index: 2;
    width: 28px;
    height: 28px;
}

.loading__logo {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 22px);
    /* A zero-width column centres the name on the spinner without using transform,
       which the fade-in animation below already uses. */
    width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    white-space: nowrap;
    animation: logoFadeIn 1s ease-out forwards;
}

@keyframes logoFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.loading__logo-text {
    font-family: 'Zen Kaku Gothic New', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #00475b;
    letter-spacing: 0.1em;
}

.loading__logo-sub {
    font-size: 0.8rem;
    color: #00695c;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-top: 5px;
}

.loading__spinner {
    display: block;
    width: 28px;
    height: 28px;
    overflow: visible;
}

.loading__spinner circle {
    fill: #2b6a64;
    fill-opacity: 0;
    stroke: #2b6a64;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-dasharray: 62.83;
    stroke-dashoffset: 45;
}

.loading__spinner.is-spinning {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* =========================================
   Scroll reveal
   Every revealed block shares one duration, distance and easing so the page
   moves with a single rhythm. Stagger with --reveal-delay where needed.
   ========================================= */
:root {
    --reveal-duration: 900ms;
    --reveal-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --reveal-distance: 24px;
    --reveal-stagger: 90ms;
}

.fade-in-blur {
    opacity: 0;
    filter: blur(6px);
    transform: translateY(var(--reveal-distance));
    transition: opacity var(--reveal-duration) var(--reveal-ease),
        filter var(--reveal-duration) var(--reveal-ease),
        transform var(--reveal-duration) var(--reveal-ease);
    transition-delay: var(--reveal-delay, 0ms);
}

/* translateY(0) is kept on purpose: it preserves the stacking context that
   decorations such as the news boxes' z-index: -1 backgrounds rely on. */
.fade-in-blur.is-visible {
    opacity: 1;
    filter: none;
    transform: translateY(0);
}

/* Pop-up variant for card-like blocks: it grows from slightly smaller while it fades in,
   with a small spring at the end. The large layout blocks keep the plain fade-up. */
:root {
    --pop-duration: 720ms;
    --pop-ease: cubic-bezier(0.34, 1.45, 0.64, 1);
    --pop-scale: 0.84;
}

.fade-in-blur.reveal-pop {
    transform: translateY(calc(var(--reveal-distance) * 0.6)) scale(var(--pop-scale));
    transition: opacity 420ms ease-out,
        filter 600ms var(--reveal-ease),
        transform var(--pop-duration) var(--pop-ease);
    transition-delay: var(--reveal-delay, 0ms);
}

.fade-in-blur.reveal-pop.is-visible {
    transform: translateY(0) scale(1);
}

/* Blurring large blocks is costly on phones; the fade and rise are enough there. */
@media (max-width: 767px) {
    :root { --reveal-distance: 16px; }
    .fade-in-blur { filter: none; }
}

@media (prefers-reduced-motion: reduce) {
    .fade-in-blur,
    .fade-in-blur.reveal-pop {
        opacity: 1;
        filter: none;
        transform: translateY(0);
        transition: none;
    }
}
